Skip to content

Commit

Permalink
test(deps): bump dev-scripts, adjust decodeableMap test to avoid cons…
Browse files Browse the repository at this point in the history
…tructor (#1384)
  • Loading branch information
mshanemc authored Aug 2, 2024
1 parent c8ef449 commit e15fd1f
Show file tree
Hide file tree
Showing 4 changed files with 230 additions and 262 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
"devDependencies": {
"@jsforce/jsforce-node": "^3.4.0",
"@salesforce/cli-plugins-testkit": "^5.3.20",
"@salesforce/dev-scripts": "^10.2.8",
"@salesforce/dev-scripts": "^10.2.9",
"@types/deep-equal-in-any-order": "^1.0.1",
"@types/fast-levenshtein": "^0.0.4",
"@types/graceful-fs": "^4.1.9",
Expand Down
2 changes: 2 additions & 0 deletions src/collections/decodeableMap.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@ import { isString } from '@salesforce/ts-types';
*
* `decodeableMap.has('layout#Layout__Broker__c-v1%2E1 Broker Layout')` --> returns `true`
* `decodeableMap.has('layout#Layout__Broker__c-v9.2 Broker Layout')` --> returns `true`
*
* DO NOT PASS VALUES to the Constructor. Instantiate the class and use the methods.
*/
export class DecodeableMap<K extends string, V> extends Map<string, V> {
// Internal map of decoded keys to encoded keys.
Expand Down
9 changes: 4 additions & 5 deletions test/collections/decodeableMap.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import { DecodeableMap } from '../../src/collections/decodeableMap';

// passes on dev-scripts 10.2.2, fails on 10.2.4. I don't know why.
// possibly mocha or types/node
describe.skip('DecodeableMap', () => {
describe('DecodeableMap', () => {
let dMap: DecodeableMap<string, string>;
const layout1_key_encoded = 'Layout-v1%2E1 Layout';
const layout1_key_decoded = 'Layout-v1.1 Layout';
Expand All @@ -28,10 +28,9 @@ describe.skip('DecodeableMap', () => {
let deleteMapSpy: sinon.SinonSpy;

beforeEach(() => {
dMap = new DecodeableMap([
[layout1_key_encoded, layout1_value],
[layout9_key_decoded, layout9_value],
]);
dMap = new DecodeableMap();
dMap.set(layout1_key_encoded, layout1_value);
dMap.set(layout9_key_decoded, layout9_value);
hasMapSpy = sandbox.spy(Map.prototype, 'has');
getMapSpy = sandbox.spy(Map.prototype, 'get');
setMapSpy = sandbox.spy(Map.prototype, 'set');
Expand Down
Loading

0 comments on commit e15fd1f

Please sign in to comment.