Api/v2 #111
File diff suppressed because one or more lines are too long
+1
-227
File diff suppressed because one or more lines are too long
+1
-227
File diff suppressed because one or more lines are too long
@@ -7,11 +7,11 @@ const popularMoviesSuccess = require('test/fixtures/popular-movies-success-respo
|
|||||||
|
|
||||||
describe('As a user I want to get popular movies', () => {
|
describe('As a user I want to get popular movies', () => {
|
||||||
before(() => resetDatabase());
|
before(() => resetDatabase());
|
||||||
before(() => createCacheEntry('p:movie:1', popularMoviesSuccess));
|
before(() => createCacheEntry('pm:1', popularMoviesSuccess));
|
||||||
|
|
||||||
it('should return 200 with the information', () =>
|
it('should return 200 with the information', () =>
|
||||||
request(app)
|
request(app)
|
||||||
.get('/api/v1/tmdb/list/popular')
|
.get('/api/v2/movie/popular')
|
||||||
.expect(200)
|
.expect(200)
|
||||||
.then(response => assert.equal(response.body.results.length, 20))
|
.then(response => assert.equal(response.body.results.length, 20))
|
||||||
);
|
);
|
||||||
|
|||||||
@@ -7,11 +7,11 @@ const popularShowsSuccess = require('test/fixtures/popular-show-success-response
|
|||||||
|
|
||||||
describe('As a user I want to get popular shows', () => {
|
describe('As a user I want to get popular shows', () => {
|
||||||
before(() => resetDatabase());
|
before(() => resetDatabase());
|
||||||
before(() => createCacheEntry('p:show:1', popularShowsSuccess));
|
before(() => createCacheEntry('pt:1', popularShowsSuccess));
|
||||||
|
|
||||||
it('should return 200 with the information', () =>
|
it('should return 200 with the information', () =>
|
||||||
request(app)
|
request(app)
|
||||||
.get('/api/v1/tmdb/list/popular?type=show')
|
.get('/api/v2/show/popular')
|
||||||
.expect(200)
|
.expect(200)
|
||||||
.then(response => assert.equal(response.body.results.length, 20))
|
.then(response => assert.equal(response.body.results.length, 20))
|
||||||
);
|
);
|
||||||
|
|||||||
@@ -6,7 +6,7 @@ const interstellarQuerySuccess = require('test/fixtures/interstellar-query-movie
|
|||||||
|
|
||||||
describe('As an anonymous user I want to search for a movie', () => {
|
describe('As an anonymous user I want to search for a movie', () => {
|
||||||
before(() => resetDatabase());
|
before(() => resetDatabase());
|
||||||
before(() => createCacheEntry('mose:1:interstellar', interstellarQuerySuccess));
|
before(() => createCacheEntry('mos:1:interstellar', interstellarQuerySuccess));
|
||||||
|
|
||||||
it('should return 200 with the search results even if user is not logged in', () =>
|
it('should return 200 with the search results even if user is not logged in', () =>
|
||||||
request(app)
|
request(app)
|
||||||
|
|||||||
Reference in New Issue
Block a user