chore: import upstream snapshot with attribution
This commit is contained in:
@@ -0,0 +1,30 @@
|
||||
import Testing
|
||||
@testable import CodexBar
|
||||
|
||||
@Suite("Usage breakdown chart menu")
|
||||
@MainActor
|
||||
struct UsageBreakdownChartMenuViewTests {
|
||||
@Test
|
||||
func `valid totals remain visible when service rows are absent`() {
|
||||
#expect(
|
||||
UsageBreakdownChartMenuView.presentationState(
|
||||
hasSummary: true,
|
||||
hasChartPoints: false) == .totalsOnly)
|
||||
}
|
||||
|
||||
@Test
|
||||
func `service rows select the chart presentation`() {
|
||||
#expect(
|
||||
UsageBreakdownChartMenuView.presentationState(
|
||||
hasSummary: true,
|
||||
hasChartPoints: true) == .chart)
|
||||
}
|
||||
|
||||
@Test
|
||||
func `missing totals and service rows select the empty presentation`() {
|
||||
#expect(
|
||||
UsageBreakdownChartMenuView.presentationState(
|
||||
hasSummary: false,
|
||||
hasChartPoints: false) == .empty)
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user