예제 #1
0
        public void Fts3CommandOptimize([IncludeDataSources(TestProvName.AllSQLite)] string context, [Values(SQLiteFTS.FTS3, SQLiteFTS.FTS4)] SQLiteFTS type)
        {
            using (var db = new TestDataConnection(context))
            {
                db.AddMappingSchema(SetupFtsMapping(type));

                db.FTS3Optimize(db.GetTable <FtsTable>());

                var tableName = type.ToString() + "_TABLE";

                Assert.AreEqual($"INSERT INTO [{tableName}]([{tableName}]) VALUES('optimize')", db.LastQuery);
            }
        }