Skip to content

Commit

Permalink
Print hostname for tests
Browse files Browse the repository at this point in the history
  • Loading branch information
buzzy authored Nov 30, 2023
1 parent ebc7188 commit 78a8264
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion main_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -43,11 +43,13 @@ func Test_Check(t *testing.T) {
t.Fatalf("Required environment variable SCALR_TOKEN is not set")
}

_, ok = os.LookupEnv("SCALR_HOSTNAME")
hostname, ok = os.LookupEnv("SCALR_HOSTNAME")

Check failure on line 46 in main_test.go

View workflow job for this annotation

GitHub Actions / Run all tests

undefined: hostname
if !ok {
t.Fatalf("Required environment variable SCALR_HOSTNAME is not set")
}

t.Log("Will run tests against host: " + hostname)

Check failure on line 51 in main_test.go

View workflow job for this annotation

GitHub Actions / Run all tests

undefined: hostname

_, ok = os.LookupEnv("SCALR_ACCOUNT")
if !ok {
t.Fatalf("Required environment variable SCALR_ACCOUNT is not set")
Expand Down

0 comments on commit 78a8264

Please sign in to comment.