Skip to content
This repository has been archived by the owner on May 7, 2021. It is now read-only.

kola/tests: check for AWS friendly device name #876

Merged
merged 1 commit into from
Jun 29, 2018

Conversation

lucab
Copy link
Contributor

@lucab lucab commented Jun 28, 2018

Test covering friendly names on AWS, recently fixed on some specific instance types at coreos/bugs#2399. This invariant should not be instance-specific though.

@ajeddeloh
Copy link
Contributor

Perhaps check if any nvme devices exist first and skip if they don't? Otherwise this test gives false positives on instance types without nvme.

@lucab
Copy link
Contributor Author

lucab commented Jun 28, 2018

@ajeddeloh the idea is that every instance (booted with default parameter) has a friendly disk name for its main volume, regardless of its instance type and nvme/non-nvme. This checks that such invariant holds everywhere, as we just fixed the broken corner-case of nvme.

Copy link
Contributor

@ajeddeloh ajeddeloh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM with or without dropping the string check. I'm fine with it either way

friendlyName := "/dev/xvda"
out := c.MustSSH(c.Machines()[0], fmt.Sprintf("stat %s", friendlyName))

if strings.Contains(string(out), "No such file or directory") {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this necesary since stat should return non-zero on ENOTFOUND

Copy link
Contributor Author

@lucab lucab Jun 28, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh, does it? I think I overlooked MustSSH return value, that would be cool. I'll re-check tomorrow.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Indeed the string check here was duplicating the internal error checking. I just dropped that.

@lucab lucab merged commit 97ecc22 into coreos:master Jun 29, 2018
@lucab lucab deleted the ups/kola-tests-misc-aws branch June 29, 2018 08:55
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants