Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Pie chart to chart display-type options #214

Merged
merged 4 commits into from
Mar 4, 2024
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .go-version
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
1.91.4
1.91.5

1 change: 1 addition & 0 deletions lightstep/resource_dashboard.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ func getUnifiedQuerySchemaMap() map[string]*schema.Schema {
"big_number_v2",
"scatter_plot",
"ordered_list",
"pie",
"table",
"traces_list",
}, false),
Expand Down
13 changes: 13 additions & 0 deletions lightstep/resource_dashboard_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -989,6 +989,19 @@ func TestDisplayTypeOptions(t *testing.T) {
resource.TestCheckResourceAttr(resourceName, "group.0.chart.0.query.0.display_type_options.0.sort_direction", "asc"),
),
},
{
Config: makeDisplayTypeConfig("pie", strings.TrimSpace(`
display_type_options {
is_donut = true
}
`)),
Check: resource.ComposeTestCheckFunc(
testAccCheckMetricDashboardExists(resourceName, &dashboard),
resource.TestCheckResourceAttr(resourceName, "dashboard_name", "test display_type_options"),
resource.TestCheckResourceAttr(resourceName, "group.0.chart.0.query.0.display", "pie"),
resource.TestCheckResourceAttr(resourceName, "group.0.chart.0.query.0.display_type_options.0.is_donut", "true"),
),
},
{
Config: makeDisplayTypeConfig("table", strings.TrimSpace(`
display_type_options {
Expand Down
Loading