@ -2,8 +2,6 @@
'use strict' ;
window . bootstrap && window . bootstrap ( ) ;
describe ( 'Unit: DatasetService' , function ( ) {
var service , httpBackend ;
@ -13,7 +11,7 @@ describe('Unit: DatasetService', function() {
"tree" : "tempest_file_freshlog_0_tree.json" ,
"id" : 0 ,
"name" : "Subunit File: freshlog" }
] } ;
] } ;
beforeEach ( function ( ) {
// instantiate the app module
@ -32,7 +30,7 @@ describe('Unit: DatasetService', function() {
it ( 'should return config.json' , function ( ) {
httpBackend . whenGET ( "data/config.json" ) . respond ( exampleConfig ) ;
service . list ( ) . then ( function ( config ) {
service . list ( ) . then ( function ( config ) {
expect ( config . data ) . toEqual ( exampleConfig ) ;
} ) ;
httpBackend . flush ( ) ;
@ -40,28 +38,28 @@ describe('Unit: DatasetService', function() {
it ( 'should GET the raw file from a dataset' , function ( ) {
httpBackend . whenGET ( exampleConfig . raw ) . respond ( exampleConfig . raw ) ;
service . raw ( exampleConfig ) . then ( function ( raw ) {
service . raw ( exampleConfig ) . then ( function ( raw ) {
expect ( raw ) . toEqual ( exampleConfig . raw ) ;
} ) ;
} ) ;
it ( 'should GET the details file from a dataset' , function ( ) {
httpBackend . whenGET ( exampleConfig . details ) . respond ( exampleConfig . details ) ;
service . details ( exampleConfig ) . then ( function ( details ) {
service . details ( exampleConfig ) . then ( function ( details ) {
expect ( details ) . toEqual ( exampleConfig . details ) ;
} ) ;
} ) ;
it ( 'should GET the tree file from a dataset' , function ( ) {
httpBackend . whenGET ( exampleConfig . tree ) . respond ( exampleConfig . tree ) ;
service . tree ( exampleConfig ) . then ( function ( tree ) {
service . tree ( exampleConfig ) . then ( function ( tree ) {
expect ( tree ) . toEqual ( exampleConfig . tree ) ;
} ) ;
} ) ;
it ( 'should GET the dstat file from a dataset' , function ( ) {
httpBackend . whenGET ( exampleConfig . dstat ) . respond ( exampleConfig . dstat ) ;
service . dstat ( exampleConfig ) . then ( function ( dstat ) {
service . dstat ( exampleConfig ) . then ( function ( dstat ) {
expect ( dstat ) . toEqual ( exampleConfig . dstat ) ;
} ) ;
} ) ;