Skip to content

Commit cee3ddd

Browse files
committed
fix integration tests
1 parent 43fd2b1 commit cee3ddd

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

commands/compile/compile_test.go

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ func TestReplaceSecurityKeys(t *testing.T) {
3838
})
3939

4040
ReplaceSecurityKeys(propsWithDefaultKeys, newKeysPath, newSignKeyName, newEncryptKeyName)
41-
require.Equal(t, goldProps, propsWithDefaultKeys)
41+
require.True(t, goldProps.Equals(propsWithDefaultKeys))
4242
}
4343

4444
func TestReplaceSecurityKeysEmpty(t *testing.T) {
@@ -50,21 +50,21 @@ func TestReplaceSecurityKeysEmpty(t *testing.T) {
5050

5151
// No error should be returned since the properties map is empty
5252
ReplaceSecurityKeys(propsWithNoKeys, newKeysPath, newSignKeyName, newEncryptKeyName)
53-
require.Equal(t, goldProps, propsWithNoKeys)
53+
require.True(t, goldProps.Equals(propsWithNoKeys))
5454
}
5555

5656
func TestReplaceSecurityKeysNothingToReplace(t *testing.T) {
57-
propsWithNoKeys := properties.NewFromHashmap(map[string]string{
57+
propsWithDifferentKeys := properties.NewFromHashmap(map[string]string{
5858
"tools.openocd.path": "{runtime.tools.openocd.path}",
5959
"tools.openocd.cmd": "bin/openocd",
6060
"tools.openocd.cmd.windows": "bin/openocd.exe",
6161
})
62-
goldProps := propsWithNoKeys.Clone()
62+
goldProps := propsWithDifferentKeys.Clone()
6363
newKeysPath := "/new-keys-path"
6464
newSignKeyName := "new-signing-key.pem"
6565
newEncryptKeyName := "new-encrypt-key.pem"
6666

6767
// No error should be returned since there are no keys in the properties map
68-
ReplaceSecurityKeys(propsWithNoKeys, newKeysPath, newSignKeyName, newEncryptKeyName)
69-
require.Equal(t, goldProps, propsWithNoKeys)
68+
ReplaceSecurityKeys(propsWithDifferentKeys, newKeysPath, newSignKeyName, newEncryptKeyName)
69+
require.True(t, goldProps.Equals(propsWithDifferentKeys))
7070
}

0 commit comments

Comments
 (0)