mirror of
https://github.com/LukeHagar/libopenapi.git
synced 2025-12-07 20:47:45 +00:00
Addressed #159
Cleaned up all interesting static checks. All that is left is cosmetics. Signed-off-by: quobix <dave@quobix.com>
This commit is contained in:
@@ -113,8 +113,6 @@ func Test_extractRequiredReferenceProperties_abs3(t *testing.T) {
|
||||
assert.Len(t, props, 1)
|
||||
if runtime.GOOS != "windows" {
|
||||
assert.Equal(t, "cakes", props["/big/fat/oh/pillow.yaml"][0])
|
||||
} else {
|
||||
// assert.Equal(t, "cakes", props["C:\\big\\fat\\oh\\pillow.yaml"][0]) drive could be anything
|
||||
}
|
||||
assert.NotNil(t, data)
|
||||
}
|
||||
@@ -131,8 +129,6 @@ func Test_extractRequiredReferenceProperties_rel_full(t *testing.T) {
|
||||
assert.Len(t, props, 1)
|
||||
if runtime.GOOS != "windows" {
|
||||
assert.Equal(t, "cakes", props["/chalky/milky/camel.yaml#/a/nice/picture/of/cake"][0])
|
||||
} else {
|
||||
//assert.Equal(t, "cakes", props["C:\\chalky\\milky\\camel.yaml#/a/nice/picture/of/cake"][0])
|
||||
}
|
||||
assert.NotNil(t, data)
|
||||
}
|
||||
@@ -149,9 +145,6 @@ func Test_extractRequiredReferenceProperties_rel(t *testing.T) {
|
||||
assert.Len(t, props, 1)
|
||||
if runtime.GOOS != "windows" {
|
||||
assert.Equal(t, "cakes", props["/oh/camel.yaml#/rum/cake"][0])
|
||||
} else {
|
||||
//cwd, _ := os.Getwd()
|
||||
//assert.Equal(t, "cakes", props[filepath.Dir(cwd)+"\\oh\\camel.yaml#/rum/cake"][0])
|
||||
}
|
||||
assert.NotNil(t, data)
|
||||
}
|
||||
@@ -168,9 +161,6 @@ func Test_extractRequiredReferenceProperties_abs2(t *testing.T) {
|
||||
assert.Len(t, props, 1)
|
||||
if runtime.GOOS != "windows" {
|
||||
assert.Equal(t, "cakes", props["/oh/my/camel.yaml#/rum/cake"][0])
|
||||
} else {
|
||||
//cwd, _ := os.Getwd()
|
||||
//assert.Equal(t, "cakes", props[filepath.Dir(cwd)+"\\oh\\my\\camel.yaml#/rum/cake"][0])
|
||||
}
|
||||
assert.NotNil(t, data)
|
||||
}
|
||||
@@ -257,8 +247,6 @@ func Test_extractRequiredReferenceProperties_nocomponent_http2(t *testing.T) {
|
||||
assert.Len(t, props, 1)
|
||||
if runtime.GOOS != "windows" {
|
||||
assert.Equal(t, "cakes", props["/go-to-bed.com/no/more/cake.yaml"][0])
|
||||
} else {
|
||||
//assert.Equal(t, "cakes", props["C:\\go-to-bed.com\\no\\more\\cake.yaml"][0])
|
||||
}
|
||||
assert.NotNil(t, data)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user