Skip to content

Commit

Permalink
Fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
lucasmrod committed Nov 13, 2024
1 parent 4ed6a7a commit 973b504
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion server/service/integration_core_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -12332,7 +12332,7 @@ func (s *integrationTestSuite) TestListSoftwareVersionsTeamIdentifier() {
versionsResp := listSoftwareVersionsResponse{}
s.DoJSON("GET", "/api/latest/fleet/software/versions",
nil, http.StatusOK, &versionsResp,
"per_page", "5", "page", "0",
"per_page", "5", "page", "0", "order_key", "name", "order_direction", "desc",
)
require.Len(t, versionsResp.Software, 2)
require.Equal(t, "Safari.app", versionsResp.Software[0].Name)
Expand Down
1 change: 1 addition & 0 deletions server/service/osquery_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -1062,6 +1062,7 @@ func verifyDiscovery(t *testing.T, queries, discovery map[string]string) {
hostDetailQueryPrefix + "software_vscode_extensions": {},
hostDetailQueryPrefix + "software_macos_firefox": {},
hostDetailQueryPrefix + "battery": {},
hostDetailQueryPrefix + "software_macos_codesign": {},
}
for name := range queries {
require.NotEmpty(t, discovery[name])
Expand Down
2 changes: 1 addition & 1 deletion server/service/osquery_utils/queries_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -307,7 +307,7 @@ func TestGetDetailQueries(t *testing.T) {
queriesWithUsersAndSoftware := GetDetailQueries(context.Background(), config.FleetConfig{App: config.AppConfig{EnableScheduledQueryStats: true}}, nil, &fleet.Features{EnableHostUsers: true, EnableSoftwareInventory: true})
qs = baseQueries
qs = append(qs, "users", "users_chrome", "software_macos", "software_linux", "software_windows", "software_vscode_extensions",
"software_chrome", "scheduled_query_stats", "software_macos_firefox")
"software_chrome", "scheduled_query_stats", "software_macos_firefox", "software_macos_codesign")
require.Len(t, queriesWithUsersAndSoftware, len(qs))
sortedKeysCompare(t, queriesWithUsersAndSoftware, qs)

Expand Down

0 comments on commit 973b504

Please sign in to comment.