fable-serviceproviderbase 3.0.6 → 3.0.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "fable-serviceproviderbase",
3
- "version": "3.0.6",
3
+ "version": "3.0.8",
4
4
  "description": "Simple base classes for fable services.",
5
5
  "main": "source/Fable-ServiceProviderBase.js",
6
6
  "scripts": {
@@ -42,7 +42,7 @@
42
42
  "homepage": "https://github.com/stevenvelozo/fable-serviceproviderbase",
43
43
  "devDependencies": {
44
44
  "chai": "4.3.7",
45
- "fable": "^3.0.46",
45
+ "fable": "^3.0.64",
46
46
  "mocha": "10.2.0",
47
47
  "nyc": "^15.1.0"
48
48
  }
@@ -15,16 +15,16 @@ class FableCoreServiceProviderBase
15
15
 
16
16
  this.options = (typeof(pOptions) === 'object') ? pOptions : {};
17
17
 
18
- this.serviceType = 'Unknown';
18
+ this.serviceType = 'Unknown';
19
19
 
20
20
  // The hash will be a non-standard UUID ... the UUID service uses this base class!
21
- this.UUID = `CORESVC-${Math.floor((Math.random() * (99999 - 10000)) + 10000)}`;
21
+ this.UUID = `CORESVC-${Math.floor((Math.random() * (99999 - 10000)) + 10000)}`;
22
22
 
23
- this.Hash = (typeof(pServiceHash) === 'string') ? pServiceHash : `${this.UUID}`;
23
+ this.Hash = (typeof(pServiceHash) === 'string') ? pServiceHash : `${this.UUID}`;
24
24
  }
25
25
 
26
26
 
27
- static isFableService = true;
27
+ static isFableService = true;
28
28
 
29
29
  // After fable is initialized, it would be expected to be wired in as a normal service.
30
30
  connectFable(pFable)
@@ -28,7 +28,7 @@ class FableServiceProviderBase
28
28
 
29
29
  // Pull back a few things
30
30
  this.log = this.fable.log;
31
- this.servicesMap = this.fable.serviceMap;
31
+ this.servicesMap = this.fable.servicesMap;
32
32
  this.services = this.fable.services;
33
33
  }
34
34
 
@@ -105,7 +105,7 @@ suite
105
105
  testFable.serviceManager.addServiceType('SimpleService');
106
106
  testFable.serviceManager.instantiateServiceProvider('SimpleService', {SomeOption: true}, 'SimpleService-123');
107
107
 
108
- Expect(testFable.serviceManager.services['SimpleService']['SimpleService-123']).to.be.an('object');
108
+ Expect(testFable.serviceManager.servicesMap['SimpleService']['SimpleService-123']).to.be.an('object');
109
109
  }
110
110
  );
111
111
  test
@@ -117,12 +117,12 @@ suite
117
117
  testFable.serviceManager.addServiceType('SimpleService', SimpleService);
118
118
  let tmpSimpleService = testFable.serviceManager.instantiateServiceProvider('SimpleService', {SomeOption: true}, 'SimpleService-123');
119
119
 
120
- Expect(testFable.serviceManager.services['SimpleService']['SimpleService-123']).to.be.an('object');
120
+ Expect(testFable.serviceManager.servicesMap['SimpleService']['SimpleService-123']).to.be.an('object');
121
121
 
122
122
  // The passed-in magic stuff should work too.
123
123
  tmpSimpleService.log.info(`There were almost ${tmpSimpleService.services.DataFormat.formatterDollars(9821229.37)} dollars just lying here!`);
124
124
 
125
- Expect(testFable.serviceManager.services['SimpleService']).to.be.an('object');
125
+ Expect(testFable.serviceManager.servicesMap['SimpleService']).to.be.an('object');
126
126
 
127
127
  testFable.serviceManager.services.SimpleService.doSomething();
128
128
 
@@ -140,9 +140,9 @@ suite
140
140
 
141
141
  testFable.serviceManager.instantiateServiceProvider('SimpleService', {SomeOption: true}, 'SimpleService-13');
142
142
 
143
- testFable.serviceManager.services['SimpleService']['SimpleService-13'].doSomething();
143
+ testFable.serviceManager.servicesMap['SimpleService']['SimpleService-13'].doSomething();
144
144
 
145
- Expect(testFable.serviceManager.services['SimpleService']['SimpleService-13']).to.be.an('object');
145
+ Expect(testFable.serviceManager.servicesMap['SimpleService']['SimpleService-13']).to.be.an('object');
146
146
  }
147
147
  );
148
148
 
@@ -157,7 +157,7 @@ suite
157
157
 
158
158
  let tmpService = testFable.serviceManager.instantiateServiceProviderWithoutRegistration('SimpleService', {SomeOption: true}, 'SimpleService-99');
159
159
 
160
- Expect(testFable.serviceMap.SimpleService['SimpleService-99']).to.be.an('undefined');
160
+ Expect(testFable.servicesMap.SimpleService['SimpleService-99']).to.be.an('undefined');
161
161
 
162
162
  Expect(tmpService).to.be.an('object');
163
163
  }
@@ -237,7 +237,7 @@ suite
237
237
 
238
238
  testFable.serviceManager.connectPreinitServiceProviderInstance(tmpCoreService);
239
239
 
240
- Expect(testFable.serviceMap.MockCoreService['MockCoreService-2']).to.be.an('object');
240
+ Expect(testFable.servicesMap.MockCoreService['MockCoreService-2']).to.be.an('object');
241
241
  Expect(testFable.services.MockCoreService).to.be.an('object');
242
242
 
243
243
  Expect(testFable.services.MockCoreService.fable.log).to.be.an('object');