2014-01-01 11:40:25 -06:00
|
|
|
require.config({
|
2015-03-29 06:06:53 -05:00
|
|
|
baseUrl: 'http://localhost:9876/base/public/app',
|
2014-01-05 03:17:53 -06:00
|
|
|
|
|
|
|
paths: {
|
2014-02-08 09:38:17 -06:00
|
|
|
specs: '../test/specs',
|
2014-03-22 07:45:02 -05:00
|
|
|
mocks: '../test/mocks',
|
2014-12-23 14:01:50 -06:00
|
|
|
helpers: '../test/specs/helpers',
|
2015-03-13 05:11:31 -05:00
|
|
|
config: 'components/config',
|
2014-02-08 09:38:17 -06:00
|
|
|
kbn: 'components/kbn',
|
2014-08-16 06:13:26 -05:00
|
|
|
store: 'components/store',
|
2014-02-08 09:38:17 -06:00
|
|
|
|
|
|
|
settings: 'components/settings',
|
2014-08-07 07:35:19 -05:00
|
|
|
lodash: 'components/lodash.extended',
|
|
|
|
'lodash-src': '../vendor/lodash',
|
2014-02-08 09:38:17 -06:00
|
|
|
|
|
|
|
moment: '../vendor/moment',
|
2014-05-01 04:18:23 -05:00
|
|
|
chromath: '../vendor/chromath',
|
|
|
|
filesaver: '../vendor/filesaver',
|
2014-02-08 09:38:17 -06:00
|
|
|
|
|
|
|
angular: '../vendor/angular/angular',
|
2014-08-06 03:53:45 -05:00
|
|
|
'angular-route': '../vendor/angular/angular-route',
|
2014-11-27 07:46:01 -06:00
|
|
|
'angular-sanitize': '../vendor/angular/angular-sanitize',
|
2014-02-08 09:38:17 -06:00
|
|
|
angularMocks: '../vendor/angular/angular-mocks',
|
|
|
|
'angular-dragdrop': '../vendor/angular/angular-dragdrop',
|
|
|
|
'angular-strap': '../vendor/angular/angular-strap',
|
|
|
|
timepicker: '../vendor/angular/timepicker',
|
|
|
|
datepicker: '../vendor/angular/datepicker',
|
|
|
|
bindonce: '../vendor/angular/bindonce',
|
|
|
|
crypto: '../vendor/crypto.min',
|
|
|
|
spectrum: '../vendor/spectrum',
|
|
|
|
|
2014-08-13 12:51:27 -05:00
|
|
|
jquery: '../vendor/jquery/jquery-2.1.1.min',
|
2014-02-08 09:38:17 -06:00
|
|
|
|
2014-05-03 10:00:48 -05:00
|
|
|
bootstrap: '../vendor/bootstrap/bootstrap',
|
|
|
|
'bootstrap-tagsinput': '../vendor/tagsinput/bootstrap-tagsinput',
|
2014-02-08 09:38:17 -06:00
|
|
|
|
|
|
|
'extend-jquery': 'components/extend-jquery',
|
|
|
|
|
|
|
|
'jquery.flot': '../vendor/jquery/jquery.flot',
|
|
|
|
'jquery.flot.pie': '../vendor/jquery/jquery.flot.pie',
|
|
|
|
'jquery.flot.events': '../vendor/jquery/jquery.flot.events',
|
|
|
|
'jquery.flot.selection': '../vendor/jquery/jquery.flot.selection',
|
|
|
|
'jquery.flot.stack': '../vendor/jquery/jquery.flot.stack',
|
|
|
|
'jquery.flot.stackpercent':'../vendor/jquery/jquery.flot.stackpercent',
|
|
|
|
'jquery.flot.time': '../vendor/jquery/jquery.flot.time',
|
2014-09-23 06:51:59 -05:00
|
|
|
'jquery.flot.crosshair': '../vendor/jquery/jquery.flot.crosshair',
|
2014-10-15 09:55:46 -05:00
|
|
|
'jquery.flot.fillbelow': '../vendor/jquery/jquery.flot.fillbelow',
|
2014-02-08 09:38:17 -06:00
|
|
|
|
|
|
|
modernizr: '../vendor/modernizr-2.6.1',
|
2014-01-05 03:17:53 -06:00
|
|
|
},
|
|
|
|
|
|
|
|
shim: {
|
2014-02-08 09:38:17 -06:00
|
|
|
bootstrap: {
|
|
|
|
deps: ['jquery']
|
|
|
|
},
|
|
|
|
|
|
|
|
modernizr: {
|
|
|
|
exports: 'Modernizr'
|
|
|
|
},
|
|
|
|
|
|
|
|
angular: {
|
|
|
|
deps: ['jquery', 'config'],
|
|
|
|
exports: 'angular'
|
|
|
|
},
|
|
|
|
|
|
|
|
angularMocks: {
|
|
|
|
deps: ['angular'],
|
|
|
|
},
|
|
|
|
|
|
|
|
crypto: {
|
|
|
|
exports: 'Crypto'
|
|
|
|
},
|
|
|
|
|
|
|
|
'jquery.flot': ['jquery'],
|
|
|
|
'jquery.flot.pie': ['jquery', 'jquery.flot'],
|
|
|
|
'jquery.flot.events': ['jquery', 'jquery.flot'],
|
|
|
|
'jquery.flot.selection':['jquery', 'jquery.flot'],
|
|
|
|
'jquery.flot.stack': ['jquery', 'jquery.flot'],
|
|
|
|
'jquery.flot.stackpercent':['jquery', 'jquery.flot'],
|
|
|
|
'jquery.flot.time': ['jquery', 'jquery.flot'],
|
2014-09-23 06:51:59 -05:00
|
|
|
'jquery.flot.crosshair':['jquery', 'jquery.flot'],
|
2014-10-15 09:55:46 -05:00
|
|
|
'jquery.flot.fillbelow':['jquery', 'jquery.flot'],
|
2014-02-08 09:38:17 -06:00
|
|
|
|
2014-08-06 03:53:45 -05:00
|
|
|
'angular-route': ['angular'],
|
2014-11-27 07:46:01 -06:00
|
|
|
'angular-sanitize': ['angular'],
|
2014-10-09 19:30:23 -05:00
|
|
|
'angular-dragdrop': ['jquery', 'angular'],
|
2014-02-08 09:38:17 -06:00
|
|
|
'angular-mocks': ['angular'],
|
|
|
|
'angular-strap': ['angular', 'bootstrap','timepicker', 'datepicker'],
|
2014-11-27 07:46:01 -06:00
|
|
|
'bindonce': ['angular'],
|
2014-02-08 09:38:17 -06:00
|
|
|
|
2014-05-03 10:00:48 -05:00
|
|
|
'bootstrap-tagsinput': ['jquery'],
|
|
|
|
|
2014-02-08 09:38:17 -06:00
|
|
|
timepicker: ['jquery', 'bootstrap'],
|
|
|
|
datepicker: ['jquery', 'bootstrap'],
|
2014-01-05 03:17:53 -06:00
|
|
|
}
|
2014-01-01 11:40:25 -06:00
|
|
|
});
|
|
|
|
|
|
|
|
require([
|
2014-03-22 07:45:02 -05:00
|
|
|
'angular',
|
2014-12-23 14:01:50 -06:00
|
|
|
'config',
|
2014-03-22 07:45:02 -05:00
|
|
|
'angularMocks',
|
2014-08-06 08:57:40 -05:00
|
|
|
'app',
|
2014-12-23 14:01:50 -06:00
|
|
|
], function(angular, config) {
|
2014-04-06 03:47:14 -05:00
|
|
|
'use strict';
|
2014-03-22 07:45:02 -05:00
|
|
|
|
2014-08-06 09:11:17 -05:00
|
|
|
for (var file in window.__karma__.files) {
|
|
|
|
if (/spec\.js$/.test(file)) {
|
|
|
|
window.tests.push(file.replace(/^\/base\//, 'http://localhost:9876/base/'));
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
2014-08-06 03:53:45 -05:00
|
|
|
angular.module('grafana', ['ngRoute']);
|
|
|
|
angular.module('grafana.services', ['ngRoute', '$strap.directives']);
|
2014-07-28 11:11:52 -05:00
|
|
|
angular.module('grafana.panels', []);
|
|
|
|
angular.module('grafana.filters', []);
|
2014-12-31 05:54:12 -06:00
|
|
|
angular.module('grafana.routes', ['ngRoute']);
|
2014-03-22 07:45:02 -05:00
|
|
|
|
2014-12-31 05:54:12 -06:00
|
|
|
var specs = [
|
2014-03-22 07:45:02 -05:00
|
|
|
'specs/lexer-specs',
|
|
|
|
'specs/parser-specs',
|
|
|
|
'specs/gfunc-specs',
|
2014-08-20 03:27:30 -05:00
|
|
|
'specs/timeSeries-specs',
|
2014-08-11 08:59:03 -05:00
|
|
|
'specs/row-ctrl-specs',
|
2014-08-07 03:42:05 -05:00
|
|
|
'specs/graphiteTargetCtrl-specs',
|
2014-09-02 13:59:54 -05:00
|
|
|
'specs/graphiteDatasource-specs',
|
2014-09-02 00:05:24 -05:00
|
|
|
'specs/influxSeries-specs',
|
|
|
|
'specs/influxQueryBuilder-specs',
|
2015-03-26 07:51:29 -05:00
|
|
|
'specs/influx09-querybuilder-specs',
|
2014-08-08 10:33:00 -05:00
|
|
|
'specs/influxdb-datasource-specs',
|
2014-08-07 11:17:26 -05:00
|
|
|
'specs/graph-ctrl-specs',
|
2014-11-12 04:58:04 -06:00
|
|
|
'specs/graph-specs',
|
2014-09-29 09:57:05 -05:00
|
|
|
'specs/graph-tooltip-specs',
|
2014-08-19 03:46:08 -05:00
|
|
|
'specs/seriesOverridesCtrl-specs',
|
2015-03-29 07:30:03 -05:00
|
|
|
'specs/shareModalCtrl-specs',
|
2014-08-27 09:29:48 -05:00
|
|
|
'specs/timeSrv-specs',
|
2014-08-27 10:58:49 -05:00
|
|
|
'specs/templateSrv-specs',
|
2014-08-28 05:44:01 -05:00
|
|
|
'specs/templateValuesSrv-specs',
|
2014-05-03 10:00:48 -05:00
|
|
|
'specs/kbn-format-specs',
|
2014-08-08 06:45:42 -05:00
|
|
|
'specs/dashboardSrv-specs',
|
2014-12-31 05:54:12 -06:00
|
|
|
'specs/dashboardViewStateSrv-specs',
|
2015-01-08 02:34:46 -06:00
|
|
|
'specs/soloPanelCtrl-specs',
|
2014-12-23 14:01:50 -06:00
|
|
|
];
|
|
|
|
|
|
|
|
var pluginSpecs = (config.plugins.specs || []).map(function (spec) {
|
|
|
|
return '../plugins/' + spec;
|
2014-03-22 07:45:02 -05:00
|
|
|
});
|
|
|
|
|
2014-12-23 14:01:50 -06:00
|
|
|
require(specs.concat(pluginSpecs), function () {
|
|
|
|
window.__karma__.start();
|
|
|
|
});
|
2014-03-22 07:45:02 -05:00
|
|
|
});
|
2014-07-02 08:21:29 -05:00
|
|
|
|