mirror of
https://github.com/ansible/awx.git
synced 2024-11-02 09:51:09 +03:00
Add test directory
This commit is contained in:
parent
69b19cc06c
commit
90b3378725
18
awx/ui/client/test/karma.conf.js
Normal file
18
awx/ui/client/test/karma.conf.js
Normal file
@ -0,0 +1,18 @@
|
||||
module.exports = config => {
|
||||
config.set({
|
||||
basePath: '..',
|
||||
singleRun: true,
|
||||
autoWatch: true,
|
||||
frameworks: ['jasmine'],
|
||||
browsers: ['PhantomJS'],
|
||||
reporters: ['mocha'],
|
||||
files: [
|
||||
'components/**/*.js',
|
||||
'test/*.spec.js'
|
||||
],
|
||||
plugins: [
|
||||
'karma-jasmine'
|
||||
'karma-mocha-reporter'
|
||||
],
|
||||
});
|
||||
};
|
20
awx/ui/client/test/panel.spec.js
Normal file
20
awx/ui/client/test/panel.spec.js
Normal file
@ -0,0 +1,20 @@
|
||||
describe('Components | panel', () => {
|
||||
var $compile,
|
||||
$rootScope;
|
||||
|
||||
beforeEach(module('at.components'));
|
||||
|
||||
beforeEach(inject((_$compile_, _$rootScope_) => {
|
||||
$compile = _$compile_;
|
||||
$rootScope = _$rootScope_;
|
||||
}));
|
||||
|
||||
it('should load the navigation partial', function() {
|
||||
var element = $compile('<at-panel></at-panel>')($rootScope);
|
||||
|
||||
$rootScope.$digest();
|
||||
|
||||
console.log(element.html());
|
||||
//expect(element.html()).toContain('<nav class="navbar navbar-default" role="navigation">');
|
||||
});
|
||||
});
|
Loading…
Reference in New Issue
Block a user