X-Git-Url: http://git.indexdata.com/?a=blobdiff_plain;f=test%2Fspec%2Fmkws-config.js;h=980b2621abd04fa1c3c26d5a9fc2e2958efb83a7;hb=87f71ca01b619b8d613407cb3fcbb91d12d932fe;hp=d168fb285246ff6c69103415cbe115f1bbfd2a92;hpb=016f2007ab90d0f3d0a8bcb552b7a8b1607081de;p=mkws-moved-to-github.git diff --git a/test/spec/mkws-config.js b/test/spec/mkws-config.js index d168fb2..980b262 100644 --- a/test/spec/mkws-config.js +++ b/test/spec/mkws-config.js @@ -1,4 +1,4 @@ -/* Copyright (c) 2013-2014 IndexData ApS. http://indexdata.com +/* Copyright (c) 2013-2014 Index Data ApS. http://indexdata.com * * check mkws_config = {} object in browser * @@ -18,6 +18,10 @@ describe("Check mkws.config object", function () { expect(mkws.locale_lang.da.Location).toMatch(/^Lokation$/); }); + /* + * this is a test if the config value is a boolean JavaScript object: true or false + * and nothing else (0, '0', undefined, "false" etc.) + */ it("mkws.config service proxy enabled/disabled", function () { if (mkws.config.use_service_proxy) { expect(mkws.config.use_service_proxy).toBe(true); @@ -30,8 +34,8 @@ describe("Check mkws.config object", function () { describe("Check pazpar2 config", function () { - it("pazpar2path is a path or an full URL", function () { - expect(mkws.config.pazpar2_url).toMatch(/^(\/|https?:\/\/)/) + it("pazpar2_url is a path or an full URL", function () { + expect(mkws.config.pazpar2_url).toMatch(/^(\/|https?:\/\/|undefined$)/) }); });