Centralize weather event and driver identifiers
This commit is contained in:
@@ -22,7 +22,7 @@ func TestConvectiveOutlookSourceKinds(t *testing.T) {
|
||||
t.Fatalf("NewConvectiveOutlookSource() error = %v", err)
|
||||
}
|
||||
got := src.Kinds()
|
||||
if len(got) != 1 || got[0] != event.Kind("outlook") {
|
||||
if len(got) != 1 || got[0] != event.Kind(standards.KindOutlook) {
|
||||
t.Fatalf("Kinds() = %#v, want [outlook]", got)
|
||||
}
|
||||
}
|
||||
@@ -57,7 +57,7 @@ func TestConvectiveOutlookSourcePollEmitsRawBundle(t *testing.T) {
|
||||
t.Fatalf("Poll() returned %d events, want 1", len(events))
|
||||
}
|
||||
got := events[0]
|
||||
if got.Kind != event.Kind("outlook") {
|
||||
if got.Kind != event.Kind(standards.KindOutlook) {
|
||||
t.Fatalf("Kind = %q, want outlook", got.Kind)
|
||||
}
|
||||
if got.Schema != standards.SchemaRawSPCConvectiveOutlookV1 {
|
||||
@@ -277,7 +277,7 @@ func convectiveOutlookConfig(extra map[string]any) config.SourceConfig {
|
||||
}
|
||||
return config.SourceConfig{
|
||||
Name: "spc-test",
|
||||
Driver: driverConvectiveOutlook,
|
||||
Driver: DriverConvectiveOutlook,
|
||||
Mode: config.SourceModePoll,
|
||||
Params: params,
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user