diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 97d03e5..d0a0648 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -58,6 +58,7 @@ jobs: - name: Run real provider e2e matrix run: | go test -count=1 -v ./internal/e2e \ + -olcrtc.real-carriers=telemost,wbstream,jazz \ -run '^TestRealProviderTransportMatrix$' \ -olcrtc.real-e2e diff --git a/internal/e2e/tunnel_test.go b/internal/e2e/tunnel_test.go index 8a20682..8be24c4 100644 --- a/internal/e2e/tunnel_test.go +++ b/internal/e2e/tunnel_test.go @@ -346,6 +346,11 @@ func realE2ECaseExpectation(carrierName, transportName string) realE2EExpectatio } case "wbstream": return realE2EExpectPass + case "jazz": + if transportName == "datachannel" { + return realE2EExpectFail + } + return realE2EExpectPass default: return realE2EExpectPass } @@ -362,6 +367,54 @@ func realE2EExpectationLabel(expectation realE2EExpectation) string { } } +func TestRealE2ECaseExpectation(t *testing.T) { + tests := []struct { + name string + carrier string + transport string + want realE2EExpectation + }{ + { + name: "jazz datachannel is expected to fail", + carrier: "jazz", + transport: "datachannel", + want: realE2EExpectFail, + }, + { + name: "jazz videochannel is expected to pass", + carrier: "jazz", + transport: "videochannel", + want: realE2EExpectPass, + }, + { + name: "telemost datachannel is expected to fail", + carrier: "telemost", + transport: "datachannel", + want: realE2EExpectFail, + }, + { + name: "telemost vp8channel is expected to pass", + carrier: "telemost", + transport: "vp8channel", + want: realE2EExpectPass, + }, + { + name: "wbstream datachannel is expected to pass", + carrier: "wbstream", + transport: "datachannel", + want: realE2EExpectPass, + }, + } + + for _, tt := range tests { + t.Run(tt.name, func(t *testing.T) { + if got := realE2ECaseExpectation(tt.carrier, tt.transport); got != tt.want { + t.Fatalf("realE2ECaseExpectation(%q, %q) = %v, want %v", tt.carrier, tt.transport, got, tt.want) + } + }) + } +} + func splitTestList(value string) []string { parts := strings.Split(value, ",") items := make([]string, 0, len(parts))