591: RESTful web service testing setup

Test Case #: 591

Test Case Name: RESTful web service testing setup

System: OpenLMIS

Subsystem: Example

Test case designed by: Anna Czyrko

Design Date:25.07.2016

Short description

  • Implement WireMock from the Architecture Overview's Tech Stack (https://openlmis.atlassian.net/wiki/x/IYAKAw)
  • Inform community on usage of WireMock, if a better tool exists recommend & demo it
  • OpenLMIS Service Example should demonstrate exercising it's own RESTful API: mock external API (e.g. as if a Security Service existed), also best-effort for demonstrating Record and Playback that a service might use in production to verify other real Services are working as expected.

                                                                                                                                                   

Pre – conditions:

                                                                                                                                                                                                                                                       

 

 

Step

Action

Expected system response

Comment

1

Run Docker for openlmis-example. Enter this comments:

gradle clean

gradle build

gradle test


 

all processes must be success.
2

Check if all test passed in following files:

 openlmis-example/build/reports/integrationTest/index.html

openlmis-example/build/reports/test/index.html

 


 

 

 

 
3

Stop Docker.

 

 
4

Run Docker for openlmis-template-service.

Enter this comments:

gradle clean

gradle build

gradle test

 

 
5

Check if all test passed in following files:


 openlmis-example/build/reports/test/index.html


 

 

 

Post – conditions:

                                                                                                                   

OpenLMIS: the global initiative for powerful LMIS software