From 88f9c1e539fc21549fa639e88762f805b4d689d9 Mon Sep 17 00:00:00 2001 From: John-David Dalton Date: Mon, 29 Apr 2013 08:54:46 -0700 Subject: [PATCH] Add `modern` build test. Former-commit-id: 5f1addf774bd9d128095d477c227c4d8420ead5d --- test/test-build.js | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/test/test-build.js b/test/test-build.js index 939f237af..a39496bc0 100644 --- a/test/test-build.js +++ b/test/test-build.js @@ -771,6 +771,27 @@ /*--------------------------------------------------------------------------*/ + QUnit.module('modern modifier'); + + (function() { + asyncTest('`lodash modern`', function() { + var start = _.after(2, _.once(QUnit.start)); + + build(['-s', 'modern'], function(data) { + var basename = path.basename(data.outputPath, '.js'), + context = createContext(); + + vm.runInContext(data.source, context); + var lodash = context._; + + strictEqual(lodash.isPlainObject(Object.create(null)), true, basename); + start(); + }); + }); + }()); + + /*--------------------------------------------------------------------------*/ + QUnit.module('source-map modifier'); (function() {