Skip to content

Commit 2c0eb21

Browse files
committed
Fix faulty tests merged via #1104 for keploy
Faulty tests and templates were commited via #1104 from @Sonichigo's PR. This commit fixes the tests and templates for keploy Signed-off-by: Alex Ellis (OpenFaaS Ltd) <[email protected]>
1 parent 1020843 commit 2c0eb21

File tree

2 files changed

+28
-19
lines changed

2 files changed

+28
-19
lines changed

pkg/get/get_test.go

+23-16
Original file line numberDiff line numberDiff line change
@@ -7658,49 +7658,56 @@ func Test_DownloadKeploy(t *testing.T) {
76587658
tool := getTool(name, tools)
76597659

76607660
const toolVersion = "v2.3.0"
7661+
// keploy_darwin_all.tar.gz
7662+
// 20.4 MB
7663+
// 1 hour ago
7664+
// keploy_linux_amd64.tar.gz
7665+
// 12.4 MB
7666+
// 1 hour ago
7667+
// keploy_linux_arm64.tar.gz
7668+
// 11.4 MB
7669+
// 1 hour ago
7670+
// keploy_windows_amd64.tar.gz
7671+
// 10.4 MB
7672+
// 1 hour ago
7673+
// keploy_windows_arm64.tar.gz
76617674

76627675
tests := []test{
76637676
{
76647677
os: "linux",
76657678
arch: arch64bit,
76667679
version: toolVersion,
7667-
url: "https://github.com/keploy/keploy/releases/download/v2.3.0-beta15/keploy_linux_amd64.tar.gz",
7680+
url: "https://github.com/keploy/keploy/releases/download/v2.3.0/keploy_linux_amd64.tar.gz",
76687681
},
76697682
{
76707683
os: "linux",
76717684
arch: archARM64,
76727685
version: toolVersion,
7673-
url: "https://github.com/keploy/keploy/releases/download/v2.3.0-beta15/keploy_linux_arm64.tar.gz",
7686+
url: "https://github.com/keploy/keploy/releases/download/v2.3.0/keploy_linux_arm64.tar.gz",
76747687
},
76757688
{
76767689
os: "darwin",
7677-
arch: archDarwinARM64,
7690+
arch: arch64bit,
76787691
version: toolVersion,
7679-
url: "https://github.com/keploy/keploy/releases/download/v2.3.0-beta15/keploy_darwin_all.tar.gz",
7692+
url: "https://github.com/keploy/keploy/releases/download/v2.3.0/keploy_darwin_all.tar.gz",
76807693
},
76817694
{
7682-
os: "ming",
7683-
arch: archARM64,
7695+
os: "darwin",
7696+
arch: archDarwinARM64,
76847697
version: toolVersion,
7685-
url: "https://github.com/keploy/keploy/releases/download/v2.3.0-beta15/keploy_windows_amd64.tar.gz",
7698+
url: "https://github.com/keploy/keploy/releases/download/v2.3.0/keploy_darwin_all.tar.gz",
76867699
},
76877700
{
76887701
os: "ming",
76897702
arch: arch64bit,
76907703
version: toolVersion,
7691-
url: "https://github.com/keploy/keploy/releases/download/v2.3.0-beta15/keploy_Windows_x86_64.tar.gz",
7704+
url: "https://github.com/keploy/keploy/releases/download/v2.3.0/keploy_windows_amd64.zip",
76927705
},
76937706
{
76947707
os: "ming",
7695-
arch: "armv6l",
7696-
version: toolVersion,
7697-
url: "https://github.com/keploy/keploy/releases/download/v2.3.0-beta15/keploy_Windows_armv6.tar.gz",
7698-
},
7699-
{
7700-
os: "ming",
7701-
arch: archARM7,
7708+
arch: archARM64,
77027709
version: toolVersion,
7703-
url: "https://github.com/keploy/keploy/releases/download/v2.3.0-beta15/keploy_Windows_armv7.tar.gz",
7710+
url: "https://github.com/keploy/keploy/releases/download/v2.3.0/keploy_windows_arm64.zip",
77047711
},
77057712
}
77067713

pkg/get/tools.go

+5-3
Original file line numberDiff line numberDiff line change
@@ -4213,25 +4213,27 @@ https://github.com/{{.Owner}}/{{.Repo}}/releases/download/{{.Version}}/{{.Name}}
42134213
{{ $os := .OS }}
42144214
{{ $arch := .Arch }}
42154215
{{ $ext := "tar.gz" }}
4216+
42164217
{{- if eq .Arch "aarch64" -}}
42174218
{{$arch = "arm64"}}
42184219
{{- else if eq .Arch "arm64" -}}
42194220
{{ $arch = "arm64" }}
42204221
{{- else if eq .Arch "x86_64" -}}
42214222
{{ $arch = "amd64" }}
42224223
{{- end -}}
4224+
42234225
{{ if HasPrefix .OS "ming" -}}
42244226
{{$os = "windows"}}
42254227
{{$ext = "zip"}}
42264228
{{- end -}}
42274229
{{- if eq .OS "darwin" -}}
4228-
{{$os = "darwin_all"}}
4230+
{{$os = "darwin"}}
4231+
{{$arch = "all"}}
42294232
{{- else if eq .OS "linux" -}}
42304233
{{ $os = "linux" }}
42314234
{{- end -}}
4232-
keploy_{{$os}}.{{$ext}}
4235+
keploy_{{$os}}_{{$arch}}.{{$ext}}
42334236
`,
42344237
})
4235-
42364238
return tools
42374239
}

0 commit comments

Comments
 (0)