Skip to content

Commit

Permalink
fix testcases
Browse files Browse the repository at this point in the history
  • Loading branch information
fenrus75 committed Sep 2, 2022
1 parent 74492c7 commit d8f5c27
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions swupd/packs_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -661,14 +661,14 @@ func TestPackRenames(t *testing.T) {
// Pack from 10->30 will contain a delta due to content change (and rename).
info = ts.createPack("os-core", 10, 30, ts.path("image"))
mustHaveDeltaCount(t, info, 1)
checkFileInPack(t, ts.path("www/30/pack-os-core-from-10.tar"), fmt.Sprintf("delta/10-30-%s-%s", hashIn10, hashIn30))
checkFileInPack(t, ts.path("www/30/pack-os-core-from-10.tar"), fmt.Sprintf("delta/10-20-%s-%s", hashIn10, hashIn30))

// Pack from 10->40 will contain a delta due to content change (and rename).
info = ts.createPack("os-core", 10, 40, ts.path("image"))
mustHaveDeltaCount(t, info, 1)

// Note that the delta refers to the version of the file, which is still 30.
checkFileInPack(t, ts.path("www/40/pack-os-core-from-10.tar"), fmt.Sprintf("delta/10-30-%s-%s", hashIn10, hashIn30))
checkFileInPack(t, ts.path("www/40/pack-os-core-from-10.tar"), fmt.Sprintf("delta/10-20-%s-%s", hashIn10, hashIn30))
}

// TestPackNoDeltas will test cases where there are no delta files
Expand Down

0 comments on commit d8f5c27

Please sign in to comment.