Skip to content

Commit

Permalink
fix tests + pouchdb-plugin-helper upgrade
Browse files Browse the repository at this point in the history
  • Loading branch information
marten-de-vries committed Dec 20, 2015
1 parent e46ddbd commit 88b607d
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 7 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
"pouchdb-bulkdocs-wrapper": "^1.0.0"
},
"devDependencies": {
"pouchdb-plugin-helper": "^1.0.0"
"pouchdb-plugin-helper": "^2.0.0"
},
"scripts": {
"helper": "./node_modules/.bin/pouchdb-plugin-helper",
Expand Down
17 changes: 11 additions & 6 deletions test/functionality.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,16 +3,12 @@ import extend from 'extend';

let db;

beforeEach(() =>
db = setup()
);

afterEach(teardown);

describe('SyncAuthTests', () => {
beforeEach(async () => {
db = setup()
should.not.exist(await db.useAsAuthenticationDB({isOnlineAuthDB: false}));
});
afterEach(teardown);

it('should test the daemon', () => {
// handled by beforeEach and afterEach
Expand Down Expand Up @@ -201,6 +197,10 @@ describe('SyncAuthTests', () => {
});

describe('AsyncAuthTests', () => {
beforeEach(async () => {
db = setup()
});
afterEach(teardown);
it('should suport the basics', done => {
function cb(err) {
if (err) {
Expand All @@ -213,6 +213,11 @@ describe('AsyncAuthTests', () => {
});

describe('AsyncAuthTestsWithoutDaemon', () => {
beforeEach(async () => {
db = setup()
});
afterEach(teardown);

it('should be impossible to use the various exposed methods', () => {
should.not.exist(db.signUp);
should.not.exist(db.session);
Expand Down

0 comments on commit 88b607d

Please sign in to comment.