Improve CI error messages
Failures unique to windows require a more informative error message to diagnose.
This commit is contained in:
parent
1e0019340d
commit
8150ef0880
|
@ -120,7 +120,7 @@ func (e *Environment) ImportDirectory(path string) {
|
|||
func (e *Environment) DeleteEnvironment() {
|
||||
e.Helper()
|
||||
err := os.RemoveAll(e.RootPath)
|
||||
assert.NoError(e, err, "cleaning up the test directory")
|
||||
assert.NoErrorf(e, err, "cleaning up test directory %q", e.RootPath)
|
||||
}
|
||||
|
||||
// DeleteIfNotFailed deletes the environment's RootPath if the test hasn't failed. Otherwise
|
||||
|
|
|
@ -1154,8 +1154,9 @@ func TestAboutNodeJS(t *testing.T) {
|
|||
e.RunCommand("pulumi", "login", "--cloud-url", e.LocalURL())
|
||||
e.RunCommand("pulumi", "stack", "init", "about-nodejs")
|
||||
e.RunCommand("pulumi", "stack", "select", "about-nodejs")
|
||||
stdout, _ := e.RunCommand("pulumi", "about")
|
||||
stdout, stderr := e.RunCommand("pulumi", "about")
|
||||
e.RunCommand("pulumi", "stack", "rm", "--yes")
|
||||
// Assert we parsed the dependencies
|
||||
assert.Contains(t, stdout, "@types/node")
|
||||
assert.Containsf(t, stdout, "@types/node",
|
||||
"Did not contain expected output. stderr: \n%q", stderr)
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue