diff --git a/.babelrc b/.babelrc index 65a81b9..ec07047 100644 --- a/.babelrc +++ b/.babelrc @@ -1,11 +1,14 @@ { "presets": [ "@babel/preset-env" - ],"plugins": [ - ["@babel/plugin-transform-runtime", + ], + "plugins": [ + "istanbul", + [ + "@babel/plugin-transform-runtime", { "regenerator": true } ] - ], + ] } \ No newline at end of file diff --git a/test/server/controllers/auth.controller.test.js b/test/server/controllers/auth.controller.test.js index b304ce7..d551a65 100644 --- a/test/server/controllers/auth.controller.test.js +++ b/test/server/controllers/auth.controller.test.js @@ -39,7 +39,7 @@ describe('auth.controller', () => { }); describe('GET /api/auth/google', async () => { - it.only('should not find the current user in the database before auth', done => { + it('should not find the current user in the database before auth', done => { const userLookup = models.User.findOne({ where: { email: 'michaelrode44@gmail.com' }, }); @@ -50,7 +50,7 @@ describe('auth.controller', () => { describe('When a user successfully auths with google', () => { describe('The user has not previously registered', () => { - it.only('should create a new user record in the datbase and return the user record', done => { + it('should create a new user record in the datbase and return the user record', done => { let strategy = passport._strategies['google']; strategy._token_response = { diff --git a/test/server/services/plex/plexApi.test.js b/test/server/services/plex/plexApi.test.js index 284c713..070fdda 100644 --- a/test/server/services/plex/plexApi.test.js +++ b/test/server/services/plex/plexApi.test.js @@ -18,7 +18,9 @@ describe('plexApi', () => { it('returns url', () => { const urlParams = plexApi.getUsersUrlParams(); const url = helpers.buildUrl(urlParams); - url.should.equal('https://plex.tv/api/users?X-Plex-Token=testPlexApiToken'); + url.should.equal( + 'https://plex.tv/api/users?X-Plex-Token=testPlexApiToken', + ); }); it('handles error when building url', () => { @@ -45,13 +47,16 @@ describe('plexApi', () => { it('returns library data by sectionId', async () => { nocks.plexLibrary(); - const result = await plexApi.getLibraryDataBySection({ sectionId: 2 }); + const result = await plexApi.getLibraryDataBySection({ + sectionId: 2, + }); result.should.deep.equal( - plexResponses.getLibraryDataBySectionRaw.MediaContainer.Metadata, + plexResponses.getLibraryDataBySectionRaw.MediaContainer + .Metadata, ); }); - // it.only('handles error if passed incorrect parameters', async (done) => { + // it('handles error if passed incorrect parameters', async (done) => { // try { // await plexApi.getLibraryDataBySection('incorrect param'); // } catch (error) {