@@ -34,8 +34,9 @@ buildGoModule (finalAttrs: {
3434 # Remove some tests that can't work during a nix build
3535
3636 # Needs the build directory to be a git repo
37- sed -i "s/func TestCacheArchiverAddingUntrackedFiles/func OFF_TestCacheArchiverAddingUntrackedFiles/" commands/helpers/file_archiver_test.go
38- sed -i "s/func TestCacheArchiverAddingUntrackedUnicodeFiles/func OFF_TestCacheArchiverAddingUntrackedUnicodeFiles/" commands/helpers/file_archiver_test.go
37+ substituteInPlace commands/helpers/file_archiver_test.go \
38+ --replace-fail "func TestCacheArchiverAddingUntrackedFiles" "func OFF_TestCacheArchiverAddingUntrackedFiles" \
39+ --replace-fail "func TestCacheArchiverAddingUntrackedUnicodeFiles" "func OFF_TestCacheArchiverAddingUntrackedUnicodeFiles"
3940 rm shells/abstract_test.go
4041
4142 # No writable developer environment
@@ -56,11 +57,14 @@ buildGoModule (finalAttrs: {
5657 ''
5758 + lib . optionalString stdenv . buildPlatform . isDarwin ''
5859 # Invalid bind arguments break Unix socket tests
59- sed -i "s/func TestRunnerWrapperCommand_createListener/func OFF_TestRunnerWrapperCommand_createListener/" commands/wrapper_test.go
60+ substituteInPlace commands/wrapper_test.go \
61+ --replace-fail "func TestRunnerWrapperCommand_createListener" "func OFF_TestRunnerWrapperCommand_createListener"
6062
6163 # No keychain access during build breaks X.509 certificate tests
62- sed -i "s/func TestCertificate/func OFF_TestCertificate/" helpers/certificate/x509_test.go
63- sed -i "s/func TestClientInvalidSSL/func OFF_TestClientInvalidSSL/" network/client_test.go
64+ substituteInPlace helpers/certificate/x509_test.go \
65+ --replace-fail "func TestCertificate" "func OFF_TestCertificate"
66+ substituteInPlace network/client_test.go \
67+ --replace-fail "func TestClientInvalidSSL" "func OFF_TestClientInvalidSSL"
6468 '' ;
6569
6670 excludedPackages = [
@@ -79,7 +83,7 @@ buildGoModule (finalAttrs: {
7983 [
8084 "-X ${ ldflagsPackageVariablePrefix } .NAME=gitlab-runner"
8185 "-X ${ ldflagsPackageVariablePrefix } .VERSION=${ finalAttrs . version } "
82- "-X ${ ldflagsPackageVariablePrefix } .REVISION=${ finalAttrs . src . tag } "
86+ "-X ${ ldflagsPackageVariablePrefix } .REVISION=v ${ finalAttrs . version } "
8387 ] ;
8488
8589 preCheck = ''
0 commit comments