-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- added organisation download - generalised download code - refactored code
- Loading branch information
Showing
13 changed files
with
199 additions
and
119 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,10 @@ | ||
package au.org.ala.merit | ||
|
||
import au.org.ala.merit.command.SaveReportDataCommand | ||
import au.org.ala.merit.hub.HubSettings | ||
import au.org.ala.merit.util.ProjectGroupingHelper | ||
import grails.testing.web.controllers.ControllerUnitTest | ||
import org.apache.http.HttpStatus | ||
import spock.lang.Specification | ||
import grails.testing.web.controllers.ControllerUnitTest | ||
|
||
class ManagementUnitControllerSpec extends Specification implements ControllerUnitTest<ManagementUnitController>{ | ||
|
||
|
@@ -444,22 +443,6 @@ class ManagementUnitControllerSpec extends Specification implements ControllerUn | |
return program | ||
} | ||
|
||
def "The controller delegates to the managementUnitService to produce reports"() { | ||
setup: | ||
String fromDate = '01-07-2020' | ||
String toDate = '31-12-2020' | ||
|
||
when: | ||
params.fromDate = fromDate | ||
params.toDate = toDate | ||
controller.generateReportsInPeriod() | ||
|
||
then: | ||
1 * userService.getUser() >> [userName:'[email protected]'] | ||
1 * managementUnitService.generateReports(fromDate, toDate, _) >> [status:HttpStatus.SC_OK] | ||
response.json == [status:HttpStatus.SC_OK] | ||
} | ||
|
||
def "User adds star to the management unit "() { | ||
setup: | ||
String managementUnitId = 'p1' | ||
|
Oops, something went wrong.