From b55df4fff07eb70c54e87ba1d3a0f105926f9493 Mon Sep 17 00:00:00 2001 From: Thai Tran Date: Thu, 9 Jul 2015 11:48:50 -0700 Subject: [PATCH] Dashboard karma is missing framework files We currently have two Karma files: one for horizon and one for dashboard. Because dashboard code relies horizon, the karma conf in dashboard should include the needed files from framework. Change-Id: I06f2ebe1da845f559a6562156e8ad9e6a7ffb128 Closes-Bug: #1473176 --- openstack_dashboard/karma.conf.js | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/openstack_dashboard/karma.conf.js b/openstack_dashboard/karma.conf.js index 2c1412601c..215f69c374 100644 --- a/openstack_dashboard/karma.conf.js +++ b/openstack_dashboard/karma.conf.js @@ -83,7 +83,14 @@ module.exports = function (config) { // TODO: These should be mocked. '../../horizon/static/horizon/js/horizon.js', - '../../horizon/static/framework/util/http/http.js', + + /** + * Include framework source code from horizon that we need. + * Otherwise, karma will not be able to find them when testing. + * These files should be mocked in the foreseeable future. + */ + '../../horizon/static/framework/**/*.module.js', + '../../horizon/static/framework/**/!(*.spec|*.mock).js', /** * First, list all the files that defines application's angular modules.