-
-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #51 from PiterWeb/main
v3.0.1 Remote Controller
- Loading branch information
Showing
32 changed files
with
7,931 additions
and
4,932 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,30 @@ | ||
describe("Basic connection", () => { | ||
import * as MockRTC from 'mockrtc'; | ||
import * as fs from 'fs'; | ||
|
||
it("load", () => { | ||
const adminServer = MockRTC.getAdminServer(); | ||
adminServer.start().then(() => console.log('WebRTC Admin server started')); | ||
|
||
const mockRTC = MockRTC.getRemote({ recordMessages: true, debug: true }); | ||
|
||
const signalWasmBuffer = fs.readFileSync('../../../static/wasm/signal.wasm'); | ||
|
||
describe('Basic connection', async () => { | ||
const wasmModule = await WebAssembly.instantiate(signalWasmBuffer); | ||
|
||
const signalEncode = wasmModule.instance.exports.signalEncode as <T>(signal: T) => string; | ||
const signalDecode = wasmModule.instance.exports.signalDecode as <T>(signal: string) => T; | ||
|
||
await mockRTC.start(); | ||
|
||
it('load', async () => { | ||
cy.visit('http://localhost:34115/'); | ||
cy.wait(1000) | ||
cy.log("hello") | ||
}) | ||
cy.wait(1000); | ||
cy.log('hello'); | ||
|
||
const mockPeer = await mockRTC.buildPeer().thenEcho(); | ||
|
||
const { offer: mockOffer, setAnswer } = await mockPeer.createOffer(); | ||
|
||
}) | ||
// Start WebRTC connection from the CypressUI | ||
}); | ||
}); |
Oops, something went wrong.