(t *testing.T)
| 1776 | } |
| 1777 | |
| 1778 | func TestSingleNodeDataBlobDisabled(t *testing.T) { |
| 1779 | if testing.Short() { |
| 1780 | t.SkipNow() |
| 1781 | return |
| 1782 | } |
| 1783 | |
| 1784 | _, finish := setupDataBlobServer(t, "TestSingleNodeDataBlobDisabled", false) |
| 1785 | defer finish() |
| 1786 | |
| 1787 | for _, testRTCServicePath := range testRTCServicePaths { |
| 1788 | t.Run(fmt.Sprintf("testRTCServicePath=%s", testRTCServicePath.String()), func(t *testing.T) { |
| 1789 | pubCapture := &dataBlobCapture{} |
| 1790 | pub := createRTCClient("pub", defaultServerPort, testRTCServicePath, &testclient.Options{ |
| 1791 | AutoSubscribe: true, |
| 1792 | SignalResponseInterceptor: pubCapture.interceptor(), |
| 1793 | }) |
| 1794 | waitUntilConnected(t, pub) |
| 1795 | defer stopClients(pub) |
| 1796 | |
| 1797 | require.NoError(t, pub.SendRequest(&livekit.SignalRequest{ |
| 1798 | Message: &livekit.SignalRequest_StoreDataBlobRequest{ |
| 1799 | StoreDataBlobRequest: &livekit.StoreDataBlobRequest{ |
| 1800 | Blob: &livekit.DataBlob{ |
| 1801 | Key: &livekit.DataBlobKey{ |
| 1802 | Key: &livekit.DataBlobKey_Generic{ |
| 1803 | Generic: "blob-1", |
| 1804 | }, |
| 1805 | }, |
| 1806 | Contents: []byte("definition-bytes"), |
| 1807 | }, |
| 1808 | }, |
| 1809 | }, |
| 1810 | })) |
| 1811 | |
| 1812 | testutils.WithTimeout(t, func() string { |
| 1813 | rr := pubCapture.takeRequestResponse() |
| 1814 | if rr == nil { |
| 1815 | return "publisher did not receive RequestResponse" |
| 1816 | } |
| 1817 | if rr.Reason != livekit.RequestResponse_NOT_ALLOWED { |
| 1818 | return fmt.Sprintf("expected NOT_ALLOWED, got %s", rr.Reason) |
| 1819 | } |
| 1820 | return "" |
| 1821 | }) |
| 1822 | }) |
| 1823 | } |
| 1824 | } |
nothing calls this directly
no test coverage detected