feat(chat): add transient presence flash and 5s reconnect grace period
This commit is contained in:
1 parent
4eb88a4594
commit
cef002862e
19 files changed
+299
-37
No files matched your search
@@ -51,26 +51,26 @@ func TestGettersDefaults(t *testing.T) {
|
||||
if got := MatomoSiteID(); got != "" {
|
||||
t.Errorf("MatomoSiteID() = %q, want empty", got)
|
||||
}
|
||||
if got := HLSSegmentDuration(); got != 6 {
|
||||
t.Errorf("HLSSegmentDuration() = %d, want 6", got)
|
||||
if got := HLSSegmentDuration(); got != 2 {
|
||||
t.Errorf("HLSSegmentDuration() = %d, want 2", got)
|
||||
}
|
||||
if got := HLSWindowSize(); got != 24 {
|
||||
t.Errorf("HLSWindowSize() = %d, want 24", got)
|
||||
if got := HLSWindowSize(); got != 12 {
|
||||
t.Errorf("HLSWindowSize() = %d, want 12", got)
|
||||
}
|
||||
}
|
||||
|
||||
func TestGettersEnvFallback(t *testing.T) {
|
||||
resetRuntime(t)
|
||||
os.Setenv("HLS_SEGMENT_DURATION", "4")
|
||||
os.Setenv("HLS_WINDOW_SIZE", "12")
|
||||
os.Setenv("HLS_WINDOW_SIZE", "30")
|
||||
os.Setenv("MATOMO_URL", "https://analytics.example.com")
|
||||
os.Setenv("MATOMO_SITE_ID", "7")
|
||||
|
||||
if got := HLSSegmentDuration(); got != 4 {
|
||||
t.Errorf("HLSSegmentDuration() = %d, want 4", got)
|
||||
}
|
||||
if got := HLSWindowSize(); got != 12 {
|
||||
t.Errorf("HLSWindowSize() = %d, want 12", got)
|
||||
if got := HLSWindowSize(); got != 30 {
|
||||
t.Errorf("HLSWindowSize() = %d, want 30", got)
|
||||
}
|
||||
if got := MatomoURL(); got != "https://analytics.example.com" {
|
||||
t.Errorf("MatomoURL() = %q", got)
|
||||
|
||||
Reference in new issue
Block a user