Skip to content

Commit

Permalink
fix: code format
Browse files Browse the repository at this point in the history
Signed-off-by: WYGIN <[email protected]>
  • Loading branch information
WYGIN committed Oct 25, 2023
1 parent 43f6ec8 commit 8714d10
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
1 change: 0 additions & 1 deletion builder/config_reader.go
Original file line number Diff line number Diff line change
Expand Up @@ -270,4 +270,3 @@ func getFilePrefixSuffix(filename string) (prefix, suffix string, err error) {
}
return val[0], suffix, err

Check warning on line 271 in builder/config_reader.go

View check run for this annotation

Codecov / codecov/patch

builder/config_reader.go#L261-L271

Added lines #L261 - L271 were not covered by tests
}

8 changes: 4 additions & 4 deletions internal/builder/builder_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -1620,7 +1620,7 @@ func testBuilder(t *testing.T, when spec.G, it spec.S) {
})
})

when("when CNB_BUILD_CONFIG_DIR is defined", func () {
when("when CNB_BUILD_CONFIG_DIR is defined", func() {
var buildConfigEnvName = "CNB_BUILD_CONFIG_DIR"
var buildConfigEnvValue = "/cnb/dup-build-config-dir"
it.Before(func() {
Expand All @@ -1640,15 +1640,15 @@ func testBuilder(t *testing.T, when spec.G, it spec.S) {
it("adds the env vars as files to the image", func() {
layerTar, err := baseImage.FindLayerWithPath(buildConfigEnvValue + "/env/SOME_KEY")
h.AssertNil(t, err)
h.AssertOnTarEntry(t, layerTar, buildConfigEnvValue + "/env/SOME_KEY",
h.AssertOnTarEntry(t, layerTar, buildConfigEnvValue+"/env/SOME_KEY",
h.ContentEquals(`some-val`),
h.HasModTime(archive.NormalizedDateTime),
)
h.AssertOnTarEntry(t, layerTar, buildConfigEnvValue + "/env/OTHER_KEY.append",
h.AssertOnTarEntry(t, layerTar, buildConfigEnvValue+"/env/OTHER_KEY.append",
h.ContentEquals(`other-val`),
h.HasModTime(archive.NormalizedDateTime),
)
h.AssertOnTarEntry(t, layerTar, buildConfigEnvValue + "/env/OTHER_KEY.delim",
h.AssertOnTarEntry(t, layerTar, buildConfigEnvValue+"/env/OTHER_KEY.delim",
h.ContentEquals(`:`),
h.HasModTime(archive.NormalizedDateTime),
)
Expand Down

0 comments on commit 8714d10

Please sign in to comment.