Skip to content

Commit 03f59b6

Browse files
committed
fixup! fixup! fixup! Support pyenv on Windows
1 parent d574585 commit 03f59b6

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

test/com/ableton/PyenvTest.groovy

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -163,13 +163,18 @@ class PyenvTest extends BasePipelineTest {
163163
2.3.7
164164
'''
165165
String cygwinPyenvRoot = 'C:/pyenv'
166-
helper.addShMock("${cygwinPyenvRoot}/bin/pyenv --version", 'pyenv 1.2.3', 0)
167-
helper.addShMock("${cygwinPyenvRoot}/bin/pyenv install --list", mockPyenvVersions, 0)
166+
List shMocks = [
167+
new Tuple("${cygwinPyenvRoot}/bin/pyenv --version", 'pyenv 1.2.3', 0),
168+
new Tuple("${cygwinPyenvRoot}/bin/pyenv install --list", mockPyenvVersions, 0),
169+
]
170+
shMocks.each { mock -> helper.addShMock(mock[0], mock[1], mock[2]) }
171+
168172
helper.registerAllowedMethod('fileExists', [String]) { return true }
169173
script.env['OS'] = 'Windows_NT'
170174

171175
assertTrue(new Pyenv(script, cygwinPyenvRoot).versionSupported('2.1.3'))
172176
assertFalse(new Pyenv(script, cygwinPyenvRoot).versionSupported('2.1.3333'))
177+
shMocks.each { mock -> assertCallStackContains(mock[0]) }
173178
}
174179

175180
private String installCommands(

0 commit comments

Comments
 (0)