Skip to content

Commit

Permalink
Fix Inventory reporting e2e tests. (#782)
Browse files Browse the repository at this point in the history
  • Loading branch information
burov authored Jan 21, 2025
1 parent 8baee92 commit 9820bc2
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions e2e_tests/test_suites/inventoryreporting/test_setup.go
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ var (
timeout: 30 * time.Minute,
itemCheck: func(items map[string]*osconfigpb.Inventory_Item) error {
var foundGooget bool
var foundCowsay bool
var foundGoogleComputeEngineSSH bool
var qfeExists bool
var wuaExists bool
var windowsApplicationExist bool
Expand All @@ -64,8 +64,8 @@ var (
if item.GetInstalledPackage().GetGoogetPackage().GetPackageName() == "googet" {
foundGooget = true
}
if item.GetAvailablePackage().GetGoogetPackage().GetPackageName() == "cowsay" {
foundCowsay = true
if item.GetAvailablePackage().GetGoogetPackage().GetPackageName() == "google-compute-engine-ssh" {
foundGoogleComputeEngineSSH = true
}
if item.GetInstalledPackage().GetQfePackage() != nil {
qfeExists = true
Expand All @@ -86,8 +86,8 @@ var (
if !foundGooget {
return errors.New("did not find 'googet' in installed packages")
}
if !foundCowsay {
return errors.New("did not find 'cowsay' in available packages")
if !foundGoogleComputeEngineSSH {
return errors.New("did not find 'google-compute-engine-ssh' in available packages")
}
if !qfeExists {
return errors.New("did not find any QFE installed package")
Expand Down Expand Up @@ -267,7 +267,7 @@ func getStartupScriptGoo() string {
ss := `
echo 'Adding test repo'
googet addrepo test https://packages.cloud.google.com/yuck/repos/osconfig-agent-test-repository
googet -noconfirm install cowsay.x86_64.0.1.0@1
googet -noconfirm install google-compute-engine-ssh
%s`
return fmt.Sprintf(ss, utils.InstallOSConfigGooGet())
}
Expand Down

0 comments on commit 9820bc2

Please sign in to comment.