Skip to content

Commit f9473e7

Browse files
authored
Merge pull request #2343 from pre-commit/golang-1-18
fix tests for golang 1.18
2 parents 7189f34 + b952c99 commit f9473e7

File tree

3 files changed

+8
-2
lines changed

3 files changed

+8
-2
lines changed
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,5 @@
11
module golang-hello-world
2+
3+
go 1.18
4+
5+
require github.com/BurntSushi/toml v1.1.0
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
github.com/BurntSushi/toml v1.1.0 h1:ksErzDEI1khOiGPgpwuI7x2ebx/uXQNw7xJpn9Eq1+I=
2+
github.com/BurntSushi/toml v1.1.0/go.mod h1:CxXYINrC8qIiEnFrOxCa7Jy5BFHlXnUU2pbicEuybxQ=

tests/repository_test.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -667,7 +667,7 @@ def test_additional_golang_dependencies_installed(
667667
path = make_repo(tempdir_factory, 'golang_hooks_repo')
668668
config = make_config_from_repo(path)
669669
# A small go package
670-
deps = ['golang.org/x/example/hello']
670+
deps = ['golang.org/x/example/hello@latest']
671671
config['hooks'][0]['additional_dependencies'] = deps
672672
hook = _get_hook(config, store, 'golang-hook')
673673
binaries = os.listdir(
@@ -688,7 +688,7 @@ def test_local_golang_additional_dependencies(store):
688688
'name': 'hello',
689689
'entry': 'hello',
690690
'language': 'golang',
691-
'additional_dependencies': ['golang.org/x/example/hello'],
691+
'additional_dependencies': ['golang.org/x/example/hello@latest'],
692692
}],
693693
}
694694
hook = _get_hook(config, store, 'hello')

0 commit comments

Comments
 (0)