Merge lp://qastaging/~dooferlad/offspring/passing-ssh-key-to-slave2 into lp://qastaging/offspring

Proposed by James Tunnicliffe
Status: Merged
Approved by: Kevin McDermott
Approved revision: 100
Merge reported by: Kevin McDermott
Merged at revision: not available
Proposed branch: lp://qastaging/~dooferlad/offspring/passing-ssh-key-to-slave2
Merge into: lp://qastaging/offspring
Diff against target: 632 lines (+423/-17)
12 files modified
lib/offspring/build/bin/offspring-build (+4/-0)
lib/offspring/build/functions/ssh.sh (+23/-0)
lib/offspring/build/tests/offspring_test_key (+27/-0)
lib/offspring/build/tests/offspring_test_key.pub (+1/-0)
lib/offspring/build/tests/test.sh (+27/-0)
lib/offspring/build/wrappers/test.sh (+52/-0)
lib/offspring/master/models.py (+12/-3)
lib/offspring/master/tests/helpers.py (+2/-0)
lib/offspring/slave/slave.py (+67/-12)
lib/offspring/slave/tests/test_slave.py (+197/-2)
lib/offspring/web/queuemanager/models.py (+9/-0)
migration/002-bzr-ssh-user-key.sql (+2/-0)
To merge this branch: bzr merge lp://qastaging/~dooferlad/offspring/passing-ssh-key-to-slave2
Reviewer Review Type Date Requested Status
Kevin McDermott Approve
Review via email: mp+85165@code.qastaging.launchpad.net

This proposal supersedes a proposal from 2011-12-08.

Description of the change

Merged on top of trunk, conflicts resolved.

---

Replaces the merge lp:~dooferlad/offspring/passing-ssh-key-to-slave2 now it contains changes from lp:~bigkevmcd/offspring/passing-ssh-key-to-slave and fixes as a result of code review.

To post a comment you must log in.
Revision history for this message
Kevin McDermott (bigkevmcd) wrote : Posted in a previous version of this proposal

Some minor fixes needed and it's good to go...

#1

+ def test_currentBuildIsActive(self):

This is actually four tests hidden in one...can you split them out, your comments are really the docstrings for the other tests...

#2
+ def test_addUserToBzrSshUrl(self):

This is cool, but I'd prefer to see the comparison made more explicit, you know what the result should be, so it might be better to be explicit in the test...

expected_url = "bzr+ssh://<email address hidden>/~dooferlad/offspring/config"

Using the same technique as the implementation is no guarantee that the result is actually correct :-)

#3

+ def test_currentBuildIsActive(self):

Doesn't fit with the test naming conventions (pep8)

#4

There are a couple of minor conflicts with trunk, can merge trunk and resolve?

Other than these minor issues, looks good, nice branch :-)

review: Needs Fixing
Revision history for this message
James Tunnicliffe (dooferlad) wrote : Posted in a previous version of this proposal

On 9 December 2011 07:42, Kevin McDermott <email address hidden> wrote:

> #3
>
> +    def test_currentBuildIsActive(self):
>
> Doesn't fit with the test naming conventions (pep8)

Please clarify. It fits with the naming convention of all the other
tests doesn't it?

Thanks,

--
James Tunnicliffe

Revision history for this message
Kevin McDermott (bigkevmcd) wrote : Posted in a previous version of this proposal

Hi James,

    def test_currentBuildIsActive(self):

compared with...

    def test_slave_run_starts_server_and_logs(self):
    def test_slave_stop(self):
    def test_slave_stop_build_no_current_build(self):
    def test_slave_stop_build_with_current_build(self):
    def test_slave_start_build(self):
    def test_currentBuildIsActive(self):
    def test_addUserToBzrSshUrl(self):
    def test_start_build_with_custom_ssh_key(self):
    def test_check_ssh_key_deleted_when_build_finished(self):
    def test__check_ssh_agent(self):

Also (and I think this was my fault), test__check_ssh_agent, can you rename that to test_check_ssh_agent ?

thanks,

Kevin :-)

Revision history for this message
James Tunnicliffe (dooferlad) wrote : Posted in a previous version of this proposal

I was mostly thinking about test_addUserToBzrSshUrl(self): the other
example :-) Would you suggest test_add_user-_to_bzr_ssh_url then?

I have already fixed up the __ problem.

James

On 9 December 2011 12:03, Kevin McDermott <email address hidden> wrote:
> Hi James,
>
>    def test_currentBuildIsActive(self):
>
> compared with...
>
>    def test_slave_run_starts_server_and_logs(self):
>    def test_slave_stop(self):
>    def test_slave_stop_build_no_current_build(self):
>    def test_slave_stop_build_with_current_build(self):
>    def test_slave_start_build(self):
>    def test_currentBuildIsActive(self):
>    def test_addUserToBzrSshUrl(self):
>    def test_start_build_with_custom_ssh_key(self):
>    def test_check_ssh_key_deleted_when_build_finished(self):
>    def test__check_ssh_agent(self):
>
> Also (and I think this was my fault), test__check_ssh_agent, can you rename that to test_check_ssh_agent ?
>
> thanks,
>
> Kevin :-)
> --
> https://code.launchpad.net/~dooferlad/offspring/passing-ssh-key-to-slave2/+merge/84987
> You are the owner of lp:~dooferlad/offspring/passing-ssh-key-to-slave2.

--
James Tunnicliffe

Revision history for this message
Kevin McDermott (bigkevmcd) :
review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
The diff is not available at this time. You can reload the page or download it.

Subscribers

People subscribed via source and target branches