mirror of https://bitbucket.org/ausocean/av.git
file_test.go: Update Tests
(b *Broadcast) UnmarshalJSON no longer starts revid (see PR #510). (m *BroadcastManager) MarshalJSON no longer needs to worry about slate exit signals due to broadcast status (see PR #511).
This commit is contained in:
parent
d0cca977f5
commit
4935e542ad
|
@ -93,7 +93,6 @@ func TestBroadcastUnmarshal(t *testing.T) {
|
||||||
mac: testMAC,
|
mac: testMAC,
|
||||||
urls: []string{testURL},
|
urls: []string{testURL},
|
||||||
status: statusActive,
|
status: statusActive,
|
||||||
rv: newRevidForTest(logger, testURL, t),
|
|
||||||
},
|
},
|
||||||
in: []byte("{\"MAC\":\"" + testMAC + "\",\"URLs\":[\"" + testURL + "\"],\"Status\":\"" + statusActive + "\"}"),
|
in: []byte("{\"MAC\":\"" + testMAC + "\",\"URLs\":[\"" + testURL + "\"],\"Status\":\"" + statusActive + "\"}"),
|
||||||
},
|
},
|
||||||
|
@ -132,11 +131,10 @@ func TestBroadcastManagerMarshal(t *testing.T) {
|
||||||
newRevidForTest((*logging.TestLogger)(t), testURL, t),
|
newRevidForTest((*logging.TestLogger)(t), testURL, t),
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
slateExitSignals: newExitSignalsForTest(t, testMAC),
|
|
||||||
log: logger,
|
log: logger,
|
||||||
dogNotifier: newWatchdogNotifierForTest(t, logger),
|
dogNotifier: newWatchdogNotifierForTest(t, logger),
|
||||||
},
|
},
|
||||||
expect: []byte("{\"Broadcasts\":{\"" + testMAC + "\":{\"MAC\":\"" + testMAC + "\",\"URLs\":[\"" + testURL + "\"],\"Status\":\"" + statusSlate + "\"}},\"SlateExitSignals\":[\"" + testMAC + "\"]}"),
|
expect: []byte("{\"Broadcasts\":{\"" + testMAC + "\":{\"MAC\":\"" + testMAC + "\",\"URLs\":[\"" + testURL + "\"],\"Status\":\"" + statusSlate + "\"}}}"),
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue