mirror of
https://github.com/rcourtman/Pulse.git
synced 2026-10-25 21:20:00 +00:00
Keep connected cost fixtures compiling and reject missing live frames
Remove an unused test import exposed by source-fciz7jhb and require the quiet-aware cost probe to retain all clients and actually queue changed readings. Change-source: pulse-maintainer
This commit is contained in:
@@ -50,6 +50,9 @@ func NewQuietBroadcastProjectionProbeForTest(getState func(string) interface{},
|
||||
hub.dispatchStateBroadcast(&Message{Type: "rawData", Data: stateBroadcastRequest{}}, "")
|
||||
bytes := 0
|
||||
for _, client := range clients {
|
||||
if !hub.clients[client] {
|
||||
return 0, fmt.Errorf("cost probe lost a client")
|
||||
}
|
||||
select {
|
||||
case data := <-client.send:
|
||||
bytes += len(data)
|
||||
|
||||
@@ -85,6 +85,9 @@ func BenchmarkConnectedDashboardCost(b *testing.B) {
|
||||
if err != nil {
|
||||
b.Fatal(err)
|
||||
}
|
||||
if viewers > 0 && mode != "quiet" && mode != "cold" && wire == 0 {
|
||||
b.Fatal("live workload queued no frame")
|
||||
}
|
||||
}
|
||||
b.ReportMetric(float64(wire), "wire-B/op")
|
||||
})
|
||||
|
||||
@@ -4,8 +4,6 @@ import (
|
||||
"bytes"
|
||||
"encoding/json"
|
||||
"testing"
|
||||
|
||||
"github.com/rcourtman/pulse-go-rewrite/internal/models"
|
||||
)
|
||||
|
||||
func TestStateDeltaDispatchSharesOnlyAcceptedBaseline(t *testing.T) {
|
||||
|
||||
Reference in New Issue
Block a user