Skip to content

Commit

Permalink
internal/mod/modimports: remove duplicate test txtar file entry
Browse files Browse the repository at this point in the history
Switching from our own txtarfs package to upstream's new txtar.FS API
surfaced the fact that TestPackageFiles had duplicate file entries
for y.cue, leading to an error as the new API is stricter.

Our existing logic uses the first entry when there are duplicates,
so delete the second. This is verified by the test failing
when the first entry is deleted instead.

Signed-off-by: Daniel Martí <[email protected]>
Change-Id: Ie37a9200b5ed854379ba77884779fbf951cb35bf
Reviewed-on: https://review.gerrithub.io/c/cue-lang/cue/+/1198172
TryBot-Result: CUEcueckoo <[email protected]>
Reviewed-by: Matthew Sackman <[email protected]>
Unity-Result: CUE porcuepine <[email protected]>
  • Loading branch information
mvdan committed Jul 22, 2024
1 parent acdd41f commit 243da87
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions internal/mod/modimports/modimports_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -88,8 +88,6 @@ import (
import "other"
-- omitted.go --
-- omitted --
-- y.cue --
package y
-- sub/x.cue --
package x
import (
Expand Down

0 comments on commit 243da87

Please sign in to comment.