Skip to content

Commit

Permalink
Add test to verify has column is now case insensitive
Browse files Browse the repository at this point in the history
  • Loading branch information
alexandrebodin committed Nov 4, 2019
1 parent 10452b5 commit bba473e
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions test/integration/schema/index.js
Expand Up @@ -1048,6 +1048,24 @@ module.exports = function(knex) {
expect(exists).to.equal(true);
});
});

describe('sqlite only', function() {
if (
!knex ||
!knex.client ||
!/sqlite3/i.test(knex.client.driverName)
) {
return Promise.resolve();
}

it('checks whether a column exists with case sensitivity, resolving with a boolean', function() {
return knex.schema
.hasColumn('accounts', 'FIRST_NAME')
.then(function(exists) {
expect(exists).to.equal(true);
});
});
});
});

describe('using processorss', function() {
Expand Down

0 comments on commit bba473e

Please sign in to comment.