[Testing] Test MCT.setAssetPath

This commit is contained in:
Victor Woeltjen 2017-04-04 11:25:35 -07:00
parent 6870055033
commit 35c457b7fb

View File

@ -43,7 +43,7 @@ define([
expect(openmct.plugins).toEqual(plugins);
});
describe("when started", function () {
describe("start", function () {
beforeEach(function () {
openmct.start();
});
@ -53,5 +53,25 @@ define([
expect(mockPlugin2).toHaveBeenCalledWith(openmct);
});
});
describe("setAssetPath", function () {
var testAssetPath;
beforeEach(function () {
testAssetPath = "some/path";
openmct.legacyExtension = jasmine.createSpy('legacyExtension');
openmct.setAssetPath(testAssetPath);
});
it("internally configures the path for assets", function () {
expect(openmct.legacyExtension).toHaveBeenCalledWith(
'constants',
{
key: "ASSETS_PATH",
value: testAssetPath
}
);
});
});
});
});