0
|
1 <!DOCTYPE html>
|
|
2 <html>
|
|
3 <head>
|
|
4 <meta charset="utf-8">
|
|
5 <title>QUnit LoadHide</title>
|
|
6 <link rel="stylesheet" href="resources/qunit.css">
|
|
7 </head>
|
|
8 <body>
|
|
9 <div id="qunit"></div>
|
|
10 <div id="qunit-fixture">
|
|
11
|
|
12 <div style="width:600px;">
|
|
13 <iframe src="resources/frame.content.html" width="100%" scrolling="no"></iframe>
|
|
14 </div>
|
|
15
|
|
16 </div>
|
|
17 <script src="resources/qunit.js"></script>
|
|
18 <script src="resources/jquery.js"></script>
|
|
19 <script src="../js/iframeResizer.min.js"></script>
|
|
20 <script>
|
|
21
|
|
22 'use strict';
|
|
23 var msgId = '[iFrameSizerTest]:';
|
|
24
|
|
25 asyncTest( "postMessage Response", function() {
|
|
26
|
|
27 iFrameResize({
|
|
28 log:true,
|
|
29 bodyBackground:'wheat',
|
|
30 heightCalculationMethod:'max',
|
|
31 initCallback:function(iframe){
|
|
32 ok( true, 'Receive init message back from iFrame.' );
|
|
33 ok( 'iFrameResizer0' === iframe.id, 'iFrame id = iFrameResizer0.' );
|
|
34 start();
|
|
35 }
|
|
36 });
|
|
37 });
|
|
38
|
|
39 </script>
|
|
40 </body>
|
|
41 </html> |