mirror of
https://github.com/siderolabs/talos.git
synced 2025-11-04 18:31:49 +01:00
test: fix the integration test for no META name
When META has never been written (e.g. booted from a disk image), it won't be detected as `talosmeta`. Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
This commit is contained in:
parent
5350063340
commit
d1a0c1f983
@ -62,16 +62,16 @@ func (suite *VolumesSuite) testDiscoveredVolumes(node string) {
|
|||||||
suite.Require().NoError(err)
|
suite.Require().NoError(err)
|
||||||
|
|
||||||
expectedVolumes := map[string]struct {
|
expectedVolumes := map[string]struct {
|
||||||
Name string
|
Names []string
|
||||||
}{
|
}{
|
||||||
"META": {
|
"META": {
|
||||||
Name: "talosmeta",
|
Names: []string{"talosmeta", ""}, // if META was never written, it will not be detected
|
||||||
},
|
},
|
||||||
"STATE": {
|
"STATE": {
|
||||||
Name: "xfs",
|
Names: []string{"xfs"},
|
||||||
},
|
},
|
||||||
"EPHEMERAL": {
|
"EPHEMERAL": {
|
||||||
Name: "xfs",
|
Names: []string{"xfs"},
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -102,7 +102,7 @@ func (suite *VolumesSuite) testDiscoveredVolumes(node string) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
suite.Assert().Equal(expected.Name, dv.TypedSpec().Name, "node: ", node)
|
suite.Assert().Contains(expected.Names, dv.TypedSpec().Name, "node: %s", node)
|
||||||
|
|
||||||
delete(expectedVolumes, id)
|
delete(expectedVolumes, id)
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user