...

Text file src/cmd/go/testdata/script/mod_vendor_redundant_requirement.txt

Documentation: cmd/go/testdata/script

     1# 'go list -mod=vendor' should succeed even when go.mod contains redundant
     2# requirements. Verifies #47565.
     3go list -mod=vendor
     4
     5-- go.mod --
     6module m
     7
     8go 1.17
     9
    10require example.com/m v0.0.0
    11require example.com/m v0.0.0
    12
    13replace example.com/m v0.0.0 => ./m
    14-- m/go.mod --
    15module example.com/m
    16
    17go 1.17
    18-- m/m.go --
    19package m
    20-- use.go --
    21package use
    22
    23import _ "example.com/m"
    24-- vendor/example.com/m/m.go --
    25package m
    26-- vendor/modules.txt --
    27# example.com/m v0.0.0 => ./m
    28## explicit; go 1.17
    29example.com/m

View as plain text