Merge lp:~fwereade/pyjuju/retire-direct-constraints-creation into lp:~fwereade/pyjuju/shadow-trunk-1204

Proposed by William Reade
Status: Merged
Approved by: William Reade
Approved revision: 508
Merged at revision: 507
Proposed branch: lp:~fwereade/pyjuju/retire-direct-constraints-creation
Merge into: lp:~fwereade/pyjuju/shadow-trunk-1204
Prerequisite: lp:~fwereade/pyjuju/constraints-via-provider
Diff against target: 0 lines
To merge this branch: bzr merge lp:~fwereade/pyjuju/retire-direct-constraints-creation
Reviewer Review Type Date Requested Status
William Reade Pending
Review via email: mp+99651@code.launchpad.net

Description of the change

Remove most remaining direct uses of Constraints

The contents of constraint_test will soon scatter amongst the providers;
leaving them in as verification for now.

https://codereview.appspot.com/5933050/

To post a comment you must log in.
Revision history for this message
William Reade (fwereade) wrote :
Download full text (16.2 KiB)

Reviewers: mp+99651_code.launchpad.net,

Message:
Please take a look.

Description:
Remove most remaining direct uses of Constraints

The contents of constraint_test will soon scatter amongst the providers;
leaving them in as verification for now.

https://code.launchpad.net/~fwereade/juju/retire-direct-constraints-creation/+merge/99651

Requires:
https://code.launchpad.net/~fwereade/juju/constraints-via-provider/+merge/99650

(do not edit description out of merge proposal)

Please review this at https://codereview.appspot.com/5933050/

Affected files:
   A [revision details]
   M juju/agents/tests/test_machine.py
   M juju/agents/tests/test_provision.py
   M juju/machine/tests/test_constraints.py
   M juju/state/tests/test_firewall.py
   M juju/state/tests/test_machine.py
   M juju/state/tests/test_placement.py
   M juju/state/tests/test_relation.py
   M juju/state/tests/test_service.py
   M juju/unit/tests/test_deploy.py

Index: [revision details]
=== added file '[revision details]'
--- [revision details] 2012-01-01 00:00:00 +0000
+++ [revision details] 2012-01-01 00:00:00 +0000
@@ -0,0 +1,2 @@
+Old revision: <email address hidden>
+New revision: <email address hidden>

Index: juju/agents/tests/test_machine.py
=== modified file 'juju/agents/tests/test_machine.py'
--- juju/agents/tests/test_machine.py 2012-03-27 22:46:44 +0000
+++ juju/agents/tests/test_machine.py 2012-03-28 00:38:16 +0000
@@ -13,7 +13,8 @@
  from juju.charm.tests import local_charm_id
  from juju.charm.tests.test_repository import RepositoryTestBase
  from juju.lib.mocker import MATCH
-from juju.machine.constraints import Constraints
+from juju.machine.tests.test_constraints import (
+ dummy_constraints, series_constraints)
  from juju.state.machine import MachineStateManager, MachineState
  from juju.state.service import ServiceStateManager
  from juju.tests.common import get_test_zookeeper_address
@@ -50,8 +51,7 @@
          # the machine.
          self.service_state_manager = ServiceStateManager(self.client)
          self.service = yield self.service_state_manager.add_service_state(
- "fatality-blog", self.charm_state,
- Constraints.from_strs("dummy", []))
+ "fatality-blog", self.charm_state, dummy_constraints)

      @inlineCallbacks
      def get_agent_config(self):
@@ -60,7 +60,7 @@
          machine_state_manager = MachineStateManager(self.client)

          self.machine_state = yield machine_state_manager.add_machine_state(
- Constraints.from_strs("dummy", []).with_series("series"))
+ series_constraints)

          self.change_environment(
              JUJU_MACHINE_ID="0",

Index: juju/agents/tests/test_provision.py
=== modified file 'juju/agents/tests/test_provision.py'
--- juju/agents/tests/test_provision.py 2012-03-27 23:22:28 +0000
+++ juju/agents/tests/test_provision.py 2012-03-28 00:38:16 +0000
@@ -6,7 +6,7 @@
  from juju.agents.provision import ProvisioningAgent
  from juju.environment.environment import Environment
  from juju.environment.errors import EnvironmentsConfigError
-from juju.machine.constraints import Constraints
+from juju.mach...

508. By William Reade

merge parent

Revision history for this message
Kapil Thangavelu (hazmat) wrote :

pretty much all test cleanup, LGTM

https://codereview.appspot.com/5933050/

509. By William Reade

merge parent

510. By William Reade

merge parent

Revision history for this message
William Reade (fwereade) wrote :

*** Submitted:

Remove most remaining direct uses of Constraints

The contents of constraint_test will soon scatter amongst the providers;
leaving them in as verification for now.

R=hazmat
CC=
https://codereview.appspot.com/5933050

https://codereview.appspot.com/5933050/

Preview Diff

Empty

Subscribers

People subscribed via source and target branches

to all changes: