diff options
| author | Shinigami <[email protected]> | 2022-01-21 22:29:24 +0100 |
|---|---|---|
| committer | GitHub <[email protected]> | 2022-01-21 22:29:24 +0100 |
| commit | 60c90028ba76b7e291fdb8152425b93c41b117c9 (patch) | |
| tree | cfaf146a883f902acc351c7c2cba095c459ec36f /test/database.unit.js | |
| parent | 2da0cec2f91f54f56b509414a8b29b3831d58412 (diff) | |
| download | faker-60c90028ba76b7e291fdb8152425b93c41b117c9.tar.xz faker-60c90028ba76b7e291fdb8152425b93c41b117c9.zip | |
chore(test): migrate to vitest (#235)
Diffstat (limited to 'test/database.unit.js')
| -rw-r--r-- | test/database.unit.js | 73 |
1 files changed, 0 insertions, 73 deletions
diff --git a/test/database.unit.js b/test/database.unit.js deleted file mode 100644 index 78420fcb..00000000 --- a/test/database.unit.js +++ /dev/null @@ -1,73 +0,0 @@ -if (typeof module !== 'undefined') { - var assert = require('assert'); - var sinon = require('sinon'); - var faker = require('../lib').faker; -} - -describe('database.js', function () { - describe('column()', function () { - it('returns a column name', function () { - sinon.stub(faker.database, 'column').returns('title'); - var column = faker.database.column(); - var expected = 'title'; - - assert.strictEqual( - column, - expected, - 'The column name should be equals ' + - expected + - '. Current is ' + - column - ); - faker.database.column.restore(); - }); - }); - - describe('collation()', function () { - it('returns a collation', function () { - sinon.stub(faker.database, 'collation').returns('utf8_bin'); - var collation = faker.database.collation(); - var expected = 'utf8_bin'; - - assert.strictEqual( - collation, - expected, - 'The collation should be equals ' + - expected + - '. Current is ' + - collation - ); - faker.database.collation.restore(); - }); - }); - - describe('engine()', function () { - it('returns an engine', function () { - sinon.stub(faker.database, 'engine').returns('InnoDB'); - var engine = faker.database.engine(); - var expected = 'InnoDB'; - - assert.strictEqual( - engine, - expected, - 'The db engine should be equals ' + expected + '. Current is ' + engine - ); - faker.database.engine.restore(); - }); - }); - - describe('type()', function () { - it('returns a column type', function () { - sinon.stub(faker.database, 'type').returns('int'); - var type = faker.database.type(); - var expected = 'int'; - - assert.strictEqual( - type, - expected, - 'The column type should be equals ' + expected + '. Current is ' + type - ); - faker.database.type.restore(); - }); - }); -}); |
