Skip to content
This repository has been archived by the owner on May 8, 2019. It is now read-only.

Commit

Permalink
Fixed test, conflict with master
Browse files Browse the repository at this point in the history
  • Loading branch information
anamariamv committed Nov 20, 2016
1 parent bfeb7b0 commit f841476
Showing 1 changed file with 3 additions and 24 deletions.
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package cards.nine.app.ui.collections.jobs

import cards.nine.app.di.Injector
import cards.nine.app.ui.collections.jobs.uiactions.{ScrollUp, SingleCollectionUiActions}
import cards.nine.app.ui.collections.jobs.uiactions.SingleCollectionUiActions
import cards.nine.app.ui.commons.JobException
import cards.nine.app.ui.launcher.jobs.LauncherTestData
import cards.nine.commons.test.TaskServiceSpecification
Expand Down Expand Up @@ -65,12 +65,10 @@ class SingleCollectionJobsSpec
"Shows empty collection if it doesn't have a collection" in new SingleCollectionJobsScope {

mockThemeProcess.getTheme(any)(any) returns serviceRight(theme)
mockSingleCollectionUiActions.updateStatus(any, any) returns serviceRight(Unit)
mockSingleCollectionUiActions.initialize(any, any) returns serviceRight(Unit)

singleCollectionJobs.initialize(ScrollUp).mustRightUnit
singleCollectionJobs.initialize().mustRightUnit

there was one(mockSingleCollectionUiActions).updateStatus(false, ScrollUp)
there was one(mockSingleCollectionUiActions).initialize(true, mockCollection)

}
Expand All @@ -86,10 +84,9 @@ class SingleCollectionJobsSpec
}

mockThemeProcess.getTheme(any)(any) returns serviceRight(theme)
mockSingleCollectionUiActions.updateStatus(any, any) returns serviceRight(Unit)
mockSingleCollectionUiActions.showEmptyCollection() returns serviceRight(Unit)

singleCollectionJobs.initialize(ScrollUp).mustRightUnit
singleCollectionJobs.initialize().mustRightUnit

}
}
Expand Down Expand Up @@ -330,24 +327,6 @@ class SingleCollectionJobsSpec
}
}

"updateScroll" should {
"calls to action updateScroll" in new SingleCollectionJobsScope {

mockSingleCollectionUiActions.updateVerticalScroll(any) returns serviceRight(Unit)
singleCollectionJobs.updateScroll(scrollY).mustRightUnit
there was one(mockSingleCollectionUiActions).updateVerticalScroll(scrollY)
}
}

"setScrollType" should {
"calls to action setScrollType" in new SingleCollectionJobsScope {

mockSingleCollectionUiActions.scrollType(any) returns serviceRight(Unit)
singleCollectionJobs.setScrollType(ScrollUp).mustRightUnit
there was one(mockSingleCollectionUiActions).scrollType(ScrollUp)
}
}

"showGenericError" should {
"calls to action showGenericError" in new SingleCollectionJobsScope {

Expand Down

0 comments on commit f841476

Please sign in to comment.