Skip to content

Commit ec8fc0f

Browse files
committed
refactor: add more test cases for sqlite
1 parent b843ba1 commit ec8fc0f

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

test/sqlite.spec.js

+4
Original file line numberDiff line numberDiff line change
@@ -148,6 +148,10 @@ describe('sqlite', () => {
148148
expect(getParsedSql(sql)).to.be.equal(`SELECT * FROM "tb" WHERE NOT EXISTS (SELECT * FROM "tb" WHERE "field1" = 'c' AND "field2" = "d")`)
149149
sql = 'SELECT * FROM tb WHERE key="foo"'
150150
expect(getParsedSql(sql)).to.be.equal('SELECT * FROM "tb" WHERE "key" = "foo"')
151+
sql = 'SELECT column_name from table_name where type= "abc"'
152+
expect(getParsedSql(sql)).to.be.equal('SELECT "column_name" FROM "table_name" WHERE "type" = "abc"')
153+
sql = "SELECT partition from table_name where partition like '%'"
154+
expect(getParsedSql(sql)).to.be.equal(`SELECT "partition" FROM "table_name" WHERE "partition" LIKE '%'`)
151155
})
152156

153157
it('should support sqlify autoincrement to other db', () => {

0 commit comments

Comments
 (0)