mirror of
https://github.com/rancher/os.git
synced 2025-09-06 01:01:43 +00:00
migrate to upstream libcompose in one and a half go
This commit is contained in:
19
vendor/github.com/docker/distribution/context/version_test.go
generated
vendored
Normal file
19
vendor/github.com/docker/distribution/context/version_test.go
generated
vendored
Normal file
@@ -0,0 +1,19 @@
|
||||
package context
|
||||
|
||||
import "testing"
|
||||
|
||||
func TestVersionContext(t *testing.T) {
|
||||
ctx := Background()
|
||||
|
||||
if GetVersion(ctx) != "" {
|
||||
t.Fatalf("context should not yet have a version")
|
||||
}
|
||||
|
||||
expected := "2.1-whatever"
|
||||
ctx = WithVersion(ctx, expected)
|
||||
version := GetVersion(ctx)
|
||||
|
||||
if version != expected {
|
||||
t.Fatalf("version was not set: %q != %q", version, expected)
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user