Add test basic-auth

This commit is contained in:
Rodrigo Ramírez Norambuena
2017-03-10 04:33:27 -03:00
parent 1c235aa761
commit ceb4ef2642
4 changed files with 90 additions and 0 deletions

View File

@@ -1,4 +1,5 @@
const globalSetup = require("../global-setup");
const serverBasicAuth = require("../../servers/basic-auth.js");
const app = globalSetup.app;
const chai = require("chai");
const expect = chai.expect;
@@ -26,4 +27,19 @@ describe("Calendar module", function () {
});
});
describe("Basic auth", function() {
before(function() {
serverBasicAuth.listen(8010);
// Set config sample for use in test
process.env.MM_CONFIG_FILE = "tests/configs/modules/calendar/basic-auth.js";
});
it("Should return TestEvents", function () {
return app.client.waitUntilTextExists(".calendar", "TestEvent", 10000);
});
});
});