mirror of
https://github.com/nasa/openmct.git
synced 2025-04-23 18:33:46 +00:00
[Add] Use cacheService from decorator spec
This commit is contained in:
parent
9f29382e18
commit
1e4ff5a73f
@ -22,8 +22,11 @@
|
||||
/*global define,Promise,describe,it,expect,beforeEach,waitsFor,jasmine*/
|
||||
|
||||
define(
|
||||
["../../src/models/CachingModelDecorator"],
|
||||
function (CachingModelDecorator) {
|
||||
[
|
||||
"../../src/models/CachingModelDecorator",
|
||||
"../../src/models/ModelCacheService"
|
||||
],
|
||||
function (CachingModelDecorator, ModelCacheService) {
|
||||
"use strict";
|
||||
|
||||
describe("The caching model decorator", function () {
|
||||
@ -67,7 +70,10 @@ define(
|
||||
b: { someOtherKey: "some other value" }
|
||||
};
|
||||
mockModelService.getModels.andReturn(asPromise(testModels));
|
||||
decorator = new CachingModelDecorator(mockModelService);
|
||||
decorator = new CachingModelDecorator(
|
||||
new ModelCacheService(),
|
||||
mockModelService
|
||||
);
|
||||
});
|
||||
|
||||
it("loads models from its wrapped model service", function () {
|
||||
@ -150,4 +156,4 @@ define(
|
||||
|
||||
});
|
||||
}
|
||||
);
|
||||
);
|
||||
|
Loading…
x
Reference in New Issue
Block a user