Comparing version 1.2.2 to 1.2.3
@@ -86,3 +86,3 @@ "use strict"; | ||
exports.ImdbError = ImdbError; | ||
var deanclatworthy = new ApiHost("www.deanclatworthy.com", "/imdb/"); | ||
var deanclatworthy = new ApiHost("deanclatworthy.com", "/imdb/"); | ||
var poromenos = new ApiHost("imdbapi.poromenos.org", "/js/"); | ||
@@ -89,0 +89,0 @@ function get(name, cb) { |
@@ -5,3 +5,3 @@ { | ||
"description": "Queries unofficial imdb APIs to get movie and television information from imdb", | ||
"version": "1.2.2", | ||
"version": "1.2.3", | ||
"main": "lib/imdb.js", | ||
@@ -8,0 +8,0 @@ "homepage": "https://github.com/worr/node-imdb-api", |
@@ -111,3 +111,3 @@ "use strict"; | ||
var deanclatworthy = new ApiHost("www.deanclatworthy.com", "/imdb/"); | ||
var deanclatworthy = new ApiHost("deanclatworthy.com", "/imdb/"); | ||
var poromenos = new ApiHost("imdbapi.poromenos.org", "/js/"); | ||
@@ -114,0 +114,0 @@ |
@@ -10,3 +10,3 @@ "use strict"; | ||
module.exports.testGetSuccessful = function(test) { | ||
var scope = nock('http://www.deanclatworthy.com').get('/imdb/?q=The%20Toxic%20Avenger&yg=0').reply(200, require('./data/toxic-avenger.json')); | ||
var scope = nock('http://deanclatworthy.com').get('/imdb/?q=The%20Toxic%20Avenger&yg=0').reply(200, require('./data/toxic-avenger.json')); | ||
@@ -27,3 +27,3 @@ return imdb.get('The Toxic Avenger', testResults); | ||
module.exports.testGetRateLimited = function(test) { | ||
var scope = nock('http://www.deanclatworthy.com').get('/imdb/?q=The%20Green%20Mile&yg=0').reply(200, { code: 2, error: "rate limited" }); | ||
var scope = nock('http://deanclatworthy.com').get('/imdb/?q=The%20Green%20Mile&yg=0').reply(200, { code: 2, error: "rate limited" }); | ||
@@ -42,3 +42,3 @@ return imdb.get('The Green Mile', testResults); | ||
module.exports.testGetUnsuccessful = function(test) { | ||
var scope = nock('http://www.deanclatworthy.com').get('/imdb/?q=The%20Green%20Mile&yg=0').reply(404); | ||
var scope = nock('http://deanclatworthy.com').get('/imdb/?q=The%20Green%20Mile&yg=0').reply(404); | ||
@@ -55,3 +55,3 @@ return imdb.get('The Green Mile', testResults); | ||
module.exports.testGetMadeupMovie = function(test) { | ||
var scope = nock('http://www.deanclatworthy.com').get('/imdb/?q=asdfasdfasdf&yg=0').reply(200, { code: 1, error: "Film not found" }); | ||
var scope = nock('http://deanclatworthy.com').get('/imdb/?q=asdfasdfasdf&yg=0').reply(200, { code: 1, error: "Film not found" }); | ||
@@ -70,3 +70,3 @@ return imdb.get('asdfasdfasdf', testResults); | ||
module.exports.testGetEpisodes = function(test) { | ||
var scope = nock('http://www.deanclatworthy.com').get('/imdb/?q=How%20I%20Met%20Your%20Mother&yg=0').reply(200, require('./data/how-I-met-your-mother.json')); | ||
var scope = nock('http://deanclatworthy.com').get('/imdb/?q=How%20I%20Met%20Your%20Mother&yg=0').reply(200, require('./data/how-I-met-your-mother.json')); | ||
@@ -97,3 +97,3 @@ return imdb.get('How I Met Your Mother', testResults); | ||
module.exports.testUnsuccessfulGetEpisodes = function(test) { | ||
var scope = nock('http://www.deanclatworthy.com').get('/imdb/?q=How%20I%20Met%20Your%20Mother&yg=0').reply(200, require('./data/how-I-met-your-mother.json')); | ||
var scope = nock('http://deanclatworthy.com').get('/imdb/?q=How%20I%20Met%20Your%20Mother&yg=0').reply(200, require('./data/how-I-met-your-mother.json')); | ||
@@ -100,0 +100,0 @@ return imdb.get('How I Met Your Mother', testResults); |
@@ -10,3 +10,3 @@ "use strict"; | ||
module.exports.testGetByIdSuccessful = function(test) { | ||
var scope = nock('http://www.deanclatworthy.com').get('/imdb/?id=tt0090191').reply(200, require('./data/toxic-avenger.json')); | ||
var scope = nock('http://deanclatworthy.com').get('/imdb/?id=tt0090191').reply(200, require('./data/toxic-avenger.json')); | ||
@@ -27,3 +27,3 @@ return imdb.getById('tt0090191', testResults); | ||
module.exports.testGetByIdRateLimited = function(test) { | ||
var scope = nock('http://www.deanclatworthy.com').get('/imdb/?id=tt0090190').reply(200, { code: 2, error: "rate limited" }); | ||
var scope = nock('http://deanclatworthy.com').get('/imdb/?id=tt0090190').reply(200, { code: 2, error: "rate limited" }); | ||
@@ -42,3 +42,3 @@ return imdb.getById('tt0090190', testResults); | ||
module.exports.testGetByIdUnsuccessful = function(test) { | ||
var scope = nock('http://www.deanclatworthy.com').get('/imdb/?id=tt0090190').reply(404); | ||
var scope = nock('http://deanclatworthy.com').get('/imdb/?id=tt0090190').reply(404); | ||
@@ -55,3 +55,3 @@ return imdb.getById('tt0090190', testResults); | ||
module.exports.testGetMadeupMovie = function(test) { | ||
var scope = nock('http://www.deanclatworthy.com').get('/imdb/?id=tt0090190').reply(200, { code: 1, error: "Film not found" }); | ||
var scope = nock('http://deanclatworthy.com').get('/imdb/?id=tt0090190').reply(200, { code: 1, error: "Film not found" }); | ||
@@ -58,0 +58,0 @@ return imdb.getById('tt0090190', testResults); |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
84695