Skip to content

Commit 35c457b

Browse files
committed
[Testing] Test MCT.setAssetPath
1 parent 6870055 commit 35c457b

File tree

1 file changed

+21
-1
lines changed

1 file changed

+21
-1
lines changed

src/MCTSpec.js

Lines changed: 21 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ define([
4343
expect(openmct.plugins).toEqual(plugins);
4444
});
4545

46-
describe("when started", function () {
46+
describe("start", function () {
4747
beforeEach(function () {
4848
openmct.start();
4949
});
@@ -53,5 +53,25 @@ define([
5353
expect(mockPlugin2).toHaveBeenCalledWith(openmct);
5454
});
5555
});
56+
57+
describe("setAssetPath", function () {
58+
var testAssetPath;
59+
60+
beforeEach(function () {
61+
testAssetPath = "some/path";
62+
openmct.legacyExtension = jasmine.createSpy('legacyExtension');
63+
openmct.setAssetPath(testAssetPath);
64+
});
65+
66+
it("internally configures the path for assets", function () {
67+
expect(openmct.legacyExtension).toHaveBeenCalledWith(
68+
'constants',
69+
{
70+
key: "ASSETS_PATH",
71+
value: testAssetPath
72+
}
73+
);
74+
});
75+
});
5676
});
5777
});

0 commit comments

Comments
 (0)