[ 
https://issues.apache.org/jira/browse/STRATOS-651?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

chris snow updated STRATOS-651:
-------------------------------

    Description: 
I have an integration test suite for the CLI [1].  It currently has about 20 
tests, and has been very useful in testing that fixes on the CLI to give some 
confidence fixes do not introduce other defects.

I originally started writing tests with java and junit.  But jline hangs when 
testing the CLI in the same JVM as Junit.  I next looked at using Java 
ProcessBuilder to execute the CLI, but that was unreliable and left lots of 
processes hanging around.  I ended up with the Python and the pexpect library 
and wiremock for simulating the REST services.

I can add some more instructions for adding new tests (e.g. recording REST 
calls with wiremock) when this branch gets merged in.

The changes are contained in the branch: stratos-651-cli-test-suite [1]. In 
summary:

- there are some changes to the CLI components pom.xml
- there is a new src/test/python folder in the CLI component.

There is a Jenkins build to prove the tests are able to run on maven [2].

---
[1] 
https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=commit;h=cb3a22e8c0a07027e6a90dd6923cce08122a7c15
[2] 
https://builds.apache.org/view/All/job/Stratos-CLI-IntegrationTest-Branch-Build/

  was:
I have an integration test suite for the CLI [1].  It currently has about 18 
tests, and has been very useful in testing that fixes on the CLI do not 
introduce other defects.

I originally wrote some tests with java and junit, but for the reasons stated 
in the README.md, I ended up with python.

I'd like to integrate these tests in to the maven build so the CLI can be 
automatically tested.  I'll need to wrap my python scripts in a maven project, 
similar to discussed here [2], rather than running the scripts manually from a 
linux command line.

I've added the changes to a branch: stratos-651-cli-test-suite [3]

---
[1] https://github.com/snowch/stratos-cli-test/blob/master/README.md
[2] http://blog.berczuk.com/2009/12/continuous-integration-of-python-code.html
[3] 
https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=commit;h=cb3a22e8c0a07027e6a90dd6923cce08122a7c15


> Add a CLI integration test suite
> --------------------------------
>
>                 Key: STRATOS-651
>                 URL: https://issues.apache.org/jira/browse/STRATOS-651
>             Project: Stratos
>          Issue Type: Improvement
>          Components: CLI
>    Affects Versions: FUTURE
>            Reporter: chris snow
>         Attachments: 0001-fix-for-STRATOS-651.patch
>
>
> I have an integration test suite for the CLI [1].  It currently has about 20 
> tests, and has been very useful in testing that fixes on the CLI to give some 
> confidence fixes do not introduce other defects.
> I originally started writing tests with java and junit.  But jline hangs when 
> testing the CLI in the same JVM as Junit.  I next looked at using Java 
> ProcessBuilder to execute the CLI, but that was unreliable and left lots of 
> processes hanging around.  I ended up with the Python and the pexpect library 
> and wiremock for simulating the REST services.
> I can add some more instructions for adding new tests (e.g. recording REST 
> calls with wiremock) when this branch gets merged in.
> The changes are contained in the branch: stratos-651-cli-test-suite [1]. In 
> summary:
> - there are some changes to the CLI components pom.xml
> - there is a new src/test/python folder in the CLI component.
> There is a Jenkins build to prove the tests are able to run on maven [2].
> ---
> [1] 
> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=commit;h=cb3a22e8c0a07027e6a90dd6923cce08122a7c15
> [2] 
> https://builds.apache.org/view/All/job/Stratos-CLI-IntegrationTest-Branch-Build/



--
This message was sent by Atlassian JIRA
(v6.2#6252)

Reply via email to