You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@jclouds.apache.org by Noorul Islam K M <no...@github.com> on 2013/09/09 07:45:49 UTC
[jclouds-chef] JCLOUDS-272: Migrate unit tests from ChefApiTest to
ChefApiExpectTest. (#15)
You can merge this Pull Request by running:
git pull https://github.com/noorul/jclouds-chef jclouds-272
Or you can view, comment on it, or merge it online at:
https://github.com/jclouds/jclouds-chef/pull/15
-- Commit Summary --
* JCLOUDS-272: Migrate unit tests from ChefApiTest to ChefApiExpectTest.
-- File Changes --
M core/src/test/java/org/jclouds/chef/ChefApiExpectTest.java (29)
M core/src/test/java/org/jclouds/chef/ChefApiTest.java (17)
R core/src/test/resources/nodes_list.json (0)
-- Patch Links --
https://github.com/jclouds/jclouds-chef/pull/15.patch
https://github.com/jclouds/jclouds-chef/pull/15.diff
Re: [jclouds-chef] JCLOUDS-272: Migrate unit tests from ChefApiTest
to ChefApiExpectTest. (#15)
Posted by Noorul Islam K M <no...@github.com>.
>From IRC
<noorul> nacx: Can you merge the migrate unit test PR?
<noorul> nacx: Since, I will only be slowly migrating them, I see that
rebasing takes time.
---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-chef/pull/15#issuecomment-24506908
Re: [jclouds-chef] JCLOUDS-272: Migrate unit tests from ChefApiTest
to ChefApiExpectTest. (#15)
Posted by BuildHive <no...@github.com>.
[jclouds » jclouds-chef #390](https://buildhive.cloudbees.com/job/jclouds/job/jclouds-chef/390/) FAILURE
Looks like there's a problem with this pull request
[(what's this?)](https://www.cloudbees.com/what-is-buildhive)
---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-chef/pull/15#issuecomment-24505609
Re: [jclouds-chef] JCLOUDS-272: Migrate unit tests from ChefApiTest
to ChefApiExpectTest. (#15)
Posted by Andrew Phillips <no...@github.com>.
@noorul: Could you squash the four commits down to one?
---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-chef/pull/15#issuecomment-24493040
Re: [jclouds-chef] JCLOUDS-272: Migrate unit tests from ChefApiTest
to ChefApiExpectTest. (#15)
Posted by CloudBees pull request builder plugin <no...@github.com>.
[jclouds-chef-pull-requests #34](https://jclouds.ci.cloudbees.com/job/jclouds-chef-pull-requests/34/) SUCCESS
This pull request looks good
---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-chef/pull/15#issuecomment-24045900
Re: [jclouds-chef] JCLOUDS-272: Migrate unit tests from ChefApiTest
to ChefApiExpectTest. (#15)
Posted by CloudBees pull request builder plugin <no...@github.com>.
[jclouds-chef-pull-requests #49](https://jclouds.ci.cloudbees.com/job/jclouds-chef-pull-requests/49/) FAILURE
Looks like there's a problem with this pull request
---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-chef/pull/15#issuecomment-24505232
Re: [jclouds-chef] JCLOUDS-272: Migrate unit tests from ChefApiTest
to ChefApiExpectTest. (#15)
Posted by Andrew Phillips <no...@github.com>.
Nice! Just a general comment about adding messages for `assertTrue` tests.
---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-chef/pull/15#issuecomment-24083527
Re: [jclouds-chef] JCLOUDS-272: Migrate unit tests from ChefApiTest
to ChefApiExpectTest. (#15)
Posted by Ignasi Barrera <no...@github.com>.
So @noorul are you planning to remove the ChefApi class and migrate all tests? If that is the idea (then I owe you a :beer:) I think we can leave this PR open and add here all the commits until the ChefApi is removed and we can mark the JIRA issue as fixed.
---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-chef/pull/15#issuecomment-24081409
Re: [jclouds-chef] JCLOUDS-272: Migrate unit tests from ChefApiTest
to ChefApiExpectTest. (#15)
Posted by BuildHive <no...@github.com>.
[jclouds » jclouds-chef #367](https://buildhive.cloudbees.com/job/jclouds/job/jclouds-chef/367/) SUCCESS
This pull request looks good
[(what's this?)](https://www.cloudbees.com/what-is-buildhive)
---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-chef/pull/15#issuecomment-24159260
Re: [jclouds-chef] JCLOUDS-272: Migrate unit tests from ChefApiTest
to ChefApiExpectTest. (#15)
Posted by Andrew Phillips <no...@github.com>.
Looks good to me! @noorul Please squash down to a single commit.
---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-chef/pull/15#issuecomment-24220961
Re: [jclouds-chef] JCLOUDS-272: Migrate unit tests from ChefApiTest
to ChefApiExpectTest. (#15)
Posted by CloudBees pull request builder plugin <no...@github.com>.
[jclouds-chef-pull-requests #41](https://jclouds.ci.cloudbees.com/job/jclouds-chef-pull-requests/41/) SUCCESS
This pull request looks good
---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-chef/pull/15#issuecomment-24159352
Re: [jclouds-chef] JCLOUDS-272: Migrate unit tests from ChefApiTest
to ChefApiExpectTest. (#15)
Posted by CloudBees pull request builder plugin <no...@github.com>.
[jclouds-chef-pull-requests #47](https://jclouds.ci.cloudbees.com/job/jclouds-chef-pull-requests/47/) SUCCESS
This pull request looks good
---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-chef/pull/15#issuecomment-24492774
Re: [jclouds-chef] JCLOUDS-272: Migrate unit tests from ChefApiTest
to ChefApiExpectTest. (#15)
Posted by CloudBees pull request builder plugin <no...@github.com>.
[jclouds-chef-pull-requests #46](https://jclouds.ci.cloudbees.com/job/jclouds-chef-pull-requests/46/) FAILURE
Looks like there's a problem with this pull request
---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-chef/pull/15#issuecomment-24491764
Re: [jclouds-chef] JCLOUDS-272: Migrate unit tests from ChefApiTest
to ChefApiExpectTest. (#15)
Posted by Noorul Islam K M <no...@github.com>.
@nacx told me on IRC that, it is going to be a single commit for entire migration. This pull request will be used for reviews. @nacx, correct me if I am wrong.
---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-chef/pull/15#issuecomment-24221406
Re: [jclouds-chef] JCLOUDS-272: Migrate unit tests from ChefApiTest
to ChefApiExpectTest. (#15)
Posted by BuildHive <no...@github.com>.
[jclouds » jclouds-chef #365](https://buildhive.cloudbees.com/job/jclouds/job/jclouds-chef/365/) SUCCESS
This pull request looks good
[(what's this?)](https://www.cloudbees.com/what-is-buildhive)
---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-chef/pull/15#issuecomment-24157412
Re: [jclouds-chef] JCLOUDS-272: Migrate unit tests from ChefApiTest
to ChefApiExpectTest. (#15)
Posted by BuildHive <no...@github.com>.
[jclouds » jclouds-chef #389](https://buildhive.cloudbees.com/job/jclouds/job/jclouds-chef/389/) FAILURE
Looks like there's a problem with this pull request
[(what's this?)](https://www.cloudbees.com/what-is-buildhive)
---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-chef/pull/15#issuecomment-24505198
Re: [jclouds-chef] JCLOUDS-272: Migrate unit tests from ChefApiTest
to ChefApiExpectTest. (#15)
Posted by BuildHive <no...@github.com>.
[jclouds » jclouds-chef #384](https://buildhive.cloudbees.com/job/jclouds/job/jclouds-chef/384/) FAILURE
Looks like there's a problem with this pull request
[(what's this?)](https://www.cloudbees.com/what-is-buildhive)
---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-chef/pull/15#issuecomment-24491692
Re: [jclouds-chef] JCLOUDS-272: Migrate unit tests from ChefApiTest
to ChefApiExpectTest. (#15)
Posted by Ignasi Barrera <no...@github.com>.
Yes, that's the idea. The issue is about migrating all tests and removing
the ChefApiTest class, but the PR only moves a couple tests. On IRC chat
@noorul and I agreed to keep this PR open, add the commits here as he
progresses (moving all tests is quite a tedious work), and squash them once
all have been migrated, to merge the PR. Sounds good?
On Wednesday, 11 September 2013, Noorul Islam K M wrote:
> @nacx <https://github.com/nacx> told me on IRC that, it is going to be a
> single commit for entire migration. This pull request will be used for
> reviews. @nacx <https://github.com/nacx>, correct me if I am wrong.
>
> —
> Reply to this email directly or view it on GitHub<https://github.com/jclouds/jclouds-chef/pull/15#issuecomment-24221406>
> .
>
---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-chef/pull/15#issuecomment-24266195
Re: [jclouds-chef] JCLOUDS-272: Migrate unit tests from ChefApiTest
to ChefApiExpectTest. (#15)
Posted by CloudBees pull request builder plugin <no...@github.com>.
[jclouds-chef-pull-requests #40](https://jclouds.ci.cloudbees.com/job/jclouds-chef-pull-requests/40/) SUCCESS
This pull request looks good
---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-chef/pull/15#issuecomment-24157461
Re: [jclouds-chef] JCLOUDS-272: Migrate unit tests from ChefApiTest
to ChefApiExpectTest. (#15)
Posted by Andrew Phillips <no...@github.com>.
> Sounds good?
Works for me!
---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-chef/pull/15#issuecomment-24281039
Re: [jclouds-chef] JCLOUDS-272: Migrate unit tests from ChefApiTest
to ChefApiExpectTest. (#15)
Posted by Noorul Islam K M <no...@github.com>.
Just rebase
---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-chef/pull/15#issuecomment-24491671
Re: [jclouds-chef] JCLOUDS-272: Migrate unit tests from ChefApiTest
to ChefApiExpectTest. (#15)
Posted by Andrew Phillips <no...@github.com>.
> @@ -46,6 +46,60 @@ public ChefApiExpectTest() {
> provider = "chef";
> }
>
> + public void testListClientsReturns2xx() {
> + ChefApi api = requestSendsResponse(
> + signed(HttpRequest.builder() //
> + .method("GET") //
> + .endpoint("http://localhost:4000/clients") //
> + .addHeader("X-Chef-Version", ChefApi.VERSION) //
> + .addHeader("Accept", MediaType.APPLICATION_JSON).build()), //
> + HttpResponse.builder().statusCode(200)
> + .payload(payloadFromResourceWithContentType("/clients_list.json", MediaType.APPLICATION_JSON)) //
> + .build());
> + Set<String> nodes = api.listClients();
> + assertEquals(nodes.size(), 3);
> + assertTrue(nodes.contains("adam"));
Add a message? E.g.
```
assertTrue(nodes.contains("adam"), "Expected nodes to contain 'adam' but was: %", nodes);
```
---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-chef/pull/15/files#r6239242
Re: [jclouds-chef] JCLOUDS-272: Migrate unit tests from ChefApiTest
to ChefApiExpectTest. (#15)
Posted by CloudBees pull request builder plugin <no...@github.com>.
[jclouds-chef-pull-requests #32](https://jclouds.ci.cloudbees.com/job/jclouds-chef-pull-requests/32/) SUCCESS
This pull request looks good
---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-chef/pull/15#issuecomment-24044085
Re: [jclouds-chef] JCLOUDS-272: Migrate unit tests from ChefApiTest
to ChefApiExpectTest. (#15)
Posted by CloudBees pull request builder plugin <no...@github.com>.
[jclouds-chef-pull-requests #50](https://jclouds.ci.cloudbees.com/job/jclouds-chef-pull-requests/50/) FAILURE
Looks like there's a problem with this pull request
---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-chef/pull/15#issuecomment-24505709
Re: [jclouds-chef] JCLOUDS-272: Migrate unit tests from ChefApiTest
to ChefApiExpectTest. (#15)
Posted by Ignasi Barrera <no...@github.com>.
Merged! As talked in the IRC, individual pull requests will be opened, and we'll mark the issue as resolved once the `ChefApiTest` class is removed.
---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-chef/pull/15#issuecomment-24508490
Re: [jclouds-chef] JCLOUDS-272: Migrate unit tests from ChefApiTest
to ChefApiExpectTest. (#15)
Posted by CloudBees pull request builder plugin <no...@github.com>.
[jclouds-chef-pull-requests #51](https://jclouds.ci.cloudbees.com/job/jclouds-chef-pull-requests/51/) SUCCESS
This pull request looks good
---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-chef/pull/15#issuecomment-24506105
Re: [jclouds-chef] JCLOUDS-272: Migrate unit tests from ChefApiTest
to ChefApiExpectTest. (#15)
Posted by Noorul Islam K M <no...@github.com>.
Yes, that is the idea.
---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-chef/pull/15#issuecomment-24085485
Re: [jclouds-chef] JCLOUDS-272: Migrate unit tests from ChefApiTest
to ChefApiExpectTest. (#15)
Posted by Ignasi Barrera <no...@github.com>.
This is great @noorul . Thanks for starting this!
---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-chef/pull/15#issuecomment-24078429