aboutsummaryrefslogblamecommitdiffstats
path: root/vendor/desandro/imagesloaded/test/unit/single-element.js
blob: 42d7e48eeb4af92eb71b237fec56c01e28be419b (plain) (tree)
1
2
3
4
5
6
7
8
9
10
11










                                                              
QUnit.test( 'single element', function( assert ) {
  'use strict';
  var elem = document.querySelector('#mario-with-shell');
  var done = assert.async();
  imagesLoaded( elem ).on( 'done', function( obj ) {
    assert.ok( true, 'single element worked' );
    assert.ok( obj.images, 'argument has images' );
    assert.equal( obj.images.length, 1, 'images.length = 1' );
    done();
  });
});