@@ -60,9 +60,9 @@ describe('CollectionEffects', () => {
6060 } ) ;
6161
6262 describe ( 'loadCollection$' , ( ) => {
63- it ( 'should return a collection.LoadSuccessAction , with the books, on success' , ( ) => {
64- const action = new collection . LoadAction ( ) ;
65- const completion = new collection . LoadSuccessAction ( [ book1 , book2 ] ) ;
63+ it ( 'should return a collection.LoadSuccess , with the books, on success' , ( ) => {
64+ const action = new collection . Load ( ) ;
65+ const completion = new collection . LoadSuccess ( [ book1 , book2 ] ) ;
6666
6767 actions$ . stream = hot ( '-a' , { a : action } ) ;
6868 const response = cold ( '-a-b|' , { a : book1 , b : book2 } ) ;
@@ -72,10 +72,10 @@ describe('CollectionEffects', () => {
7272 expect ( effects . loadCollection$ ) . toBeObservable ( expected ) ;
7373 } ) ;
7474
75- it ( 'should return a collection.LoadFailAction , if the query throws' , ( ) => {
76- const action = new collection . LoadAction ( ) ;
75+ it ( 'should return a collection.LoadFail , if the query throws' , ( ) => {
76+ const action = new collection . Load ( ) ;
7777 const error = 'Error!' ;
78- const completion = new collection . LoadFailAction ( error ) ;
78+ const completion = new collection . LoadFail ( error ) ;
7979
8080 actions$ . stream = hot ( '-a' , { a : action } ) ;
8181 const response = cold ( '-#' , { } , error ) ;
@@ -87,9 +87,9 @@ describe('CollectionEffects', () => {
8787 } ) ;
8888
8989 describe ( 'addBookToCollection$' , ( ) => {
90- it ( 'should return a collection.AddBookSuccessAction , with the book, on success' , ( ) => {
91- const action = new collection . AddBookAction ( book1 ) ;
92- const completion = new collection . AddBookSuccessAction ( book1 ) ;
90+ it ( 'should return a collection.AddBookSuccess , with the book, on success' , ( ) => {
91+ const action = new collection . AddBook ( book1 ) ;
92+ const completion = new collection . AddBookSuccess ( book1 ) ;
9393
9494 actions$ . stream = hot ( '-a' , { a : action } ) ;
9595 const response = cold ( '-b' , { b : true } ) ;
@@ -100,9 +100,9 @@ describe('CollectionEffects', () => {
100100 expect ( db . insert ) . toHaveBeenCalledWith ( 'books' , [ book1 ] ) ;
101101 } ) ;
102102
103- it ( 'should return a collection.AddBookFailAction , with the book, when the db insert throws' , ( ) => {
104- const action = new collection . AddBookAction ( book1 ) ;
105- const completion = new collection . AddBookFailAction ( book1 ) ;
103+ it ( 'should return a collection.AddBookFail , with the book, when the db insert throws' , ( ) => {
104+ const action = new collection . AddBook ( book1 ) ;
105+ const completion = new collection . AddBookFail ( book1 ) ;
106106 const error = 'Error!' ;
107107
108108 actions$ . stream = hot ( '-a' , { a : action } ) ;
@@ -114,9 +114,9 @@ describe('CollectionEffects', () => {
114114 } ) ;
115115
116116 describe ( 'removeBookFromCollection$' , ( ) => {
117- it ( 'should return a collection.RemoveBookSuccessAction , with the book, on success' , ( ) => {
118- const action = new collection . RemoveBookAction ( book1 ) ;
119- const completion = new collection . RemoveBookSuccessAction ( book1 ) ;
117+ it ( 'should return a collection.RemoveBookSuccess , with the book, on success' , ( ) => {
118+ const action = new collection . RemoveBook ( book1 ) ;
119+ const completion = new collection . RemoveBookSuccess ( book1 ) ;
120120
121121 actions$ . stream = hot ( '-a' , { a : action } ) ;
122122 const response = cold ( '-b' , { b : true } ) ;
@@ -129,9 +129,9 @@ describe('CollectionEffects', () => {
129129 ] ) ;
130130 } ) ;
131131
132- it ( 'should return a collection.RemoveBookFailAction , with the book, when the db insert throws' , ( ) => {
133- const action = new collection . RemoveBookAction ( book1 ) ;
134- const completion = new collection . RemoveBookFailAction ( book1 ) ;
132+ it ( 'should return a collection.RemoveBookFail , with the book, when the db insert throws' , ( ) => {
133+ const action = new collection . RemoveBook ( book1 ) ;
134+ const completion = new collection . RemoveBookFail ( book1 ) ;
135135 const error = 'Error!' ;
136136
137137 actions$ . stream = hot ( '-a' , { a : action } ) ;
0 commit comments