@@ -25,7 +25,6 @@ import java.nio.file.Path
25
25
import kotlin.test.Test
26
26
import kotlin.test.assertContains
27
27
import kotlin.test.assertEquals
28
- import kotlin.test.assertNotEquals
29
28
30
29
internal class CoderSettingsTest {
31
30
private val logger = mockk<Logger >(relaxed = true )
@@ -114,6 +113,7 @@ internal class CoderSettingsTest {
114
113
assertEquals(Path .of(expected).toAbsolutePath(), settings.readOnly().binPath(newUrl).parent)
115
114
}
116
115
116
+ @Test
117
117
fun testBinPath () {
118
118
val settings = CoderSettingsStore (
119
119
pluginTestSettingsStore(
@@ -134,7 +134,7 @@ internal class CoderSettingsTest {
134
134
expected = " /tmp/coder-toolbox-test/data-dir/localhost"
135
135
assertEquals(Path .of(expected).toAbsolutePath(), settings.readOnly().binPath(url, true ).parent)
136
136
137
- assertNotEquals (" foo-bar.baz" , settings.readOnly().binPath(url).fileName.toString())
137
+ assertEquals (" foo-bar.baz" , settings.readOnly().binPath(url).fileName.toString())
138
138
}
139
139
140
140
@Test
@@ -158,7 +158,7 @@ internal class CoderSettingsTest {
158
158
OS .MAC -> " /tmp/coder-toolbox-test/cli-home/Library/Application Support/coderv2"
159
159
else -> " /tmp/coder-toolbox-test/cli-xdg-config/coderv2"
160
160
}
161
- assertEquals(expected, settings.readOnly().globalConfigDir)
161
+ assertEquals(Path .of( expected), Path .of( settings.readOnly().globalConfigDir) )
162
162
163
163
// Fall back to HOME on Linux.
164
164
if (getOS() == OS .LINUX ) {
@@ -174,7 +174,7 @@ internal class CoderSettingsTest {
174
174
logger
175
175
)
176
176
expected = " /tmp/coder-toolbox-test/cli-home/.config/coderv2"
177
- assertEquals(expected, settings.readOnly().globalConfigDir)
177
+ assertEquals(Path .of( expected), Path .of( settings.readOnly().globalConfigDir) )
178
178
}
179
179
180
180
// Read CODER_CONFIG_DIR.
@@ -193,7 +193,7 @@ internal class CoderSettingsTest {
193
193
logger
194
194
)
195
195
expected = " /tmp/coder-toolbox-test/coder-config-dir"
196
- assertEquals(expected, settings.readOnly().globalConfigDir)
196
+ assertEquals(Path .of( expected), Path .of( settings.readOnly().globalConfigDir) )
197
197
}
198
198
199
199
@Test
0 commit comments