Skip to content

Commit

Permalink
test: fix test for windows
Browse files Browse the repository at this point in the history
  • Loading branch information
shetzel committed Mar 4, 2024
1 parent 5ed314f commit 5d8b216
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions test/hooks/diagnostics.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -72,8 +72,10 @@ describe('Doctor diagnostics', () => {

expect(addPluginDataStub.callCount, 'Expected doctor.addPluginData() to be called once').to.equal(1);
expect(addPluginDataStub.args[0][0]).to.equal(pluginName);
// The generic keychain is used on Windows necessarily, so expect true rather
// than using the value of process.env.SF_USE_GENERIC_UNIX_KEYCHAIN
expect(addPluginDataStub.args[0][1]).to.deep.equal({
isUsingGenericKeychain: false,
isUsingGenericKeychain: process.platform === 'win32' || false,
sfCryptoV2Support: false,
cryptoVersion: 'unknown',
sfCryptoV2: undefined,
Expand All @@ -95,8 +97,10 @@ describe('Doctor diagnostics', () => {

expect(addPluginDataStub.callCount, 'Expected doctor.addPluginData() to be called once').to.equal(1);
expect(addPluginDataStub.args[0][0]).to.equal(pluginName);
// The generic keychain is used on Windows necessarily, so expect true rather
// than using the value of process.env.SF_USE_GENERIC_UNIX_KEYCHAIN
expect(addPluginDataStub.args[0][1]).to.deep.equal({
isUsingGenericKeychain: false,
isUsingGenericKeychain: process.platform === 'win32' || false,
sfCryptoV2Support: true,
cryptoVersion: 'unknown',
sfCryptoV2: undefined,
Expand Down

0 comments on commit 5d8b216

Please sign in to comment.