Skip to content

Commit

Permalink
fix tests after device-constants update
Browse files Browse the repository at this point in the history
  • Loading branch information
hugomontero committed Dec 10, 2024
1 parent 572ecd9 commit 9b67f85
Show file tree
Hide file tree
Showing 6 changed files with 12 additions and 8 deletions.
4 changes: 2 additions & 2 deletions src/cli/cloud.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ describe('Cloud Command-Line Interface', () => {
'Display a list of your devices, as well as their variables and functions',
'Usage: particle cloud list [options] [filter]',
'',
'Param filter can be: online, offline, a platform name (core, photon, p1, electron, argon, boron, xenon, esomx, bsom, b5som, tracker, trackerm, p2, msom), a device ID or name',
'Param filter can be: online, offline, a platform name (core, photon, p1, electron, argon, boron, xenon, esomx, bsom, b5som, tracker, trackerm, p2, msom, electron2), a device ID or name',
''
].join('\n'));
});
Expand Down Expand Up @@ -308,7 +308,7 @@ describe('Cloud Command-Line Interface', () => {
' particle cloud compile photon Compile the source code in the current directory in the cloud for a `photon`',
' particle cloud compile electron project --saveTo electron.bin Compile the source code in the project directory in the cloud for an `electron` and save it to a file named `electron.bin`',
'',
'Param deviceType can be: core, c, photon, p, p1, electron, e, argon, a, boron, b, xenon, x, esomx, bsom, b5som, tracker, assettracker, trackerm, p2, photon2, msom, muon',
'Param deviceType can be: core, c, photon, p, p1, electron, e, argon, a, boron, b, xenon, x, esomx, bsom, b5som, tracker, assettracker, trackerm, p2, photon2, msom, muon, electron2',
''
].join('\n'));
});
Expand Down
2 changes: 1 addition & 1 deletion src/cli/usb.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ describe('USB Command-Line Interface', () => {
' --exclude-dfu Do not list devices which are in DFU mode [boolean]',
' --ids-only Print only device IDs [boolean]',
'',
'Param filter can be: online, offline, a platform name (core, photon, p1, electron, argon, boron, xenon, esomx, bsom, b5som, tracker, trackerm, p2, msom), a device ID or name',
'Param filter can be: online, offline, a platform name (core, photon, p1, electron, argon, boron, xenon, esomx, bsom, b5som, tracker, trackerm, p2, msom, electron2), a device ID or name',
''
].join('\n'));
});
Expand Down
1 change: 1 addition & 0 deletions src/lib/platform.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ const PLATFORMS_BY_ID = PLATFORMS.reduce((map, p) => map.set(p.id, p), new Map()
* @property {Number} TRACKERM
* @property {Number} P2
* @property {Number} MSOM
* @property {Number} ELECTRON2
*/
const PlatformId = PLATFORMS.reduce((out, p) => {
out[p.name.toUpperCase()] = p.id;
Expand Down
9 changes: 6 additions & 3 deletions src/lib/utilities.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,8 @@ describe('Utilities', () => {
'tracker': 26,
'trackerm': 28,
'p2': 32,
'msom': 35
'msom': 35,
'electron2': 37
});
});
});
Expand Down Expand Up @@ -52,7 +53,8 @@ describe('Utilities', () => {
'p2': 32,
'photon2': 32,
'msom': 35,
'muon': 35
'muon': 35,
'electron2': 37
});
});
});
Expand All @@ -73,7 +75,8 @@ describe('Utilities', () => {
26: 'Asset Tracker / Monitor One',
28: 'Tracker-M',
32: 'Photon 2 / P2',
35: 'M-SoM'
35: 'M-SoM',
37: 'Electron 2'
});
});
});
Expand Down
2 changes: 1 addition & 1 deletion test/e2e/compile.e2e.js
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ describe('Compile Commands', () => {
' particle compile photon Compile the source code in the current directory in the cloud for a `photon`',
' particle compile electron project --saveTo electron.bin Compile the source code in the project directory in the cloud for an `electron` and save it to a file named `electron.bin`',
'',
'Param deviceType can be: core, c, photon, p, p1, electron, e, argon, a, boron, b, xenon, x, esomx, bsom, b5som, tracker, assettracker, trackerm, p2, photon2, msom, muon',
'Param deviceType can be: core, c, photon, p, p1, electron, e, argon, a, boron, b, xenon, x, esomx, bsom, b5som, tracker, assettracker, trackerm, p2, photon2, msom, muon, electron2',
];

beforeEach(async () => {
Expand Down
2 changes: 1 addition & 1 deletion test/e2e/list.e2e.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ describe('List Commands', () => {
' -v, --verbose Increases how much logging to display [count]',
' -q, --quiet Decreases how much logging to display [count]',
'',
'Param filter can be: online, offline, a platform name (core, photon, p1, electron, argon, boron, xenon, esomx, bsom, b5som, tracker, trackerm, p2, msom), a device ID or name'
'Param filter can be: online, offline, a platform name (core, photon, p1, electron, argon, boron, xenon, esomx, bsom, b5som, tracker, trackerm, p2, msom, electron2), a device ID or name'
];

before(async () => {
Expand Down

0 comments on commit 9b67f85

Please sign in to comment.