Skip to content

Instantly share code, notes, and snippets.

View dijs's full-sized avatar
🏠
Working from home

Richard van der Dys dijs

🏠
Working from home
View GitHub Profile

Keybase proof

I hereby claim:

  • I am dijs on github.
  • I am dijs (https://keybase.io/dijs) on keybase.
  • I have a public key ASAwfYz8pR__vxK7rmaK-yFUWJFuB11izKq98hOv6ZDjJwo

To claim this, I am signing this object:

@dijs
dijs / jsdom-iframe-test.js
Created July 20, 2016 18:30
Example of testing iframe messaging using jsdom
import { expect } from 'chai';
import jsdom from 'jsdom';
describe('JSDOM', () => {
it('should communicate with inner iframes', done => {
jsdom.env({
url: "http://bar.com/",
done (err, window) {
var frame = window.document.createElement('iframe');
window.document.body.appendChild(frame);