I've _just_ published this package, so all of this is quite new!<p>It lets you define mock behaviour for a WebRTC peer in a couple of lines, and then connect to that mock using normal WebRTC APIs so you can write automated tests against reliable fake remote peers, quickly & easily.<p>It can also proxy WebRTC traffic, basically by creating two connections and passing data & media between them, and then hooking setup methods to automatically redirect your traffic through those. You just set up the hooks on your connection, then you connect to a real remote peer as normal, and everything gets intercepted (and then it can be rewritten, recorded, whatever you like).<p>At the moment the API is a little small, but all the traffic is intercepted and modifiable now, so extending that to cover whatever behaviours might be interesting should be relatively simple from here on, it's just a question of what to include. I've mostly focused on datachannels since that's more what I'm interested in right now, but ideas for more mock behaviours you'd find useful would be really helpful. Suggestions very welcome!