Skip to content

Commit

Permalink
tests
Browse files Browse the repository at this point in the history
  • Loading branch information
captncraig committed Nov 15, 2023
1 parent 7b4ec8f commit 83b4b6d
Showing 1 changed file with 28 additions and 0 deletions.
28 changes: 28 additions & 0 deletions internal/useragent/useragent_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,34 @@ func TestUserAgent(t *testing.T) {
Expected: "GrafanaAgent/v1.2.3 (static; linux; operator)",
GOOS: "linux",
},
{
Name: "deb",
Mode: "flow",
DeployMode: "deb",
Expected: "GrafanaAgent/v1.2.3 (flow; linux; deb)",
GOOS: "linux",
},
{
Name: "rpm",
Mode: "static",
DeployMode: "rpm",
Expected: "GrafanaAgent/v1.2.3 (static; linux; rpm)",
GOOS: "linux",
},
{
Name: "docker",
Mode: "flow",
DeployMode: "docker",
Expected: "GrafanaAgent/v1.2.3 (flow; linux; docker)",
GOOS: "linux",
},
{
Name: "helm",
Mode: "flow",
DeployMode: "helm",
Expected: "GrafanaAgent/v1.2.3 (flow; linux; helm)",
GOOS: "linux",
},
}
for _, tst := range tests {
t.Run(tst.Name, func(t *testing.T) {
Expand Down

0 comments on commit 83b4b6d

Please sign in to comment.