UNPKG

plupload

Version:

Plupload is a JavaScript API for dealing with file uploads it supports features like multiple file selection, file type filtering, request chunking, client side image scaling and it uses different runtimes to achieve this such as HTML 5, Silverlight and F

75 lines (55 loc) 1.55 kB
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8" /> <title>GoogleDrive: FileInput</title> <script src="../../../loader.js"></script> <script type="text/javascript"> QUnit.config.reorder = false; QUnit.config.testTimeout = 10000; module("GoogleDrive: FileInput", { setup: function() { }, teardown: function() { } }); test("Test initialization", function(assert) { $('#qunit-fixture').append([ '<div id="container">', '<a id="browse_button" href="javascript:;">Browse...</a>', '</div>' ].join('')); var fi = new o.FileInput({ runtime_order: 'googledrive', browse_button: 'browse_button', googledrive: { clientId: "202721612178-kl66mbigdr2t6qf949kpqi6l9uua0fib.apps.googleusercontent.com", apiKey: "AIzaSyAMqXzpUiaONoXF_fxSa0Ep3tS_QQPP4YA" } }); fi.onready = function() { start(); assert.ok(true, "Ready event has fired."); // test if gapi is loaded and picker constructor is defined assert.ok(gapi, "Google API has been loaded."); assert.ok(google && google.picker && google.picker.PickerBuilder, "PickerBuilder constructor is available."); }; fi.bind("Error RuntimeError", function() { assert.ok(true, "Runtime not supported."); start(); }); stop(); fi.init(); }); </script> </head> <body> <h1 id="qunit-header">mOxie Test Suite</h1> <h2 id="qunit-banner"></h2> <h2 id="qunit-userAgent"></h2> <ol id="qunit-tests"> </ol> <div id="qunit-fixture" style="position: relative; top: 0 !important; left: 0 !important; width: 100%; height: 9px;"></div> </body> </html>