uniter/upgrade: Added steps for setting installed #31

Merged
merged 1 commit into from Aug 20, 2015

Conversation

Projects
None yet
2 participants

mattyw commented Aug 20, 2015

No description provided.

worker/uniter/upgrade126.go
+func addInstalled(opsFile string, state *operation.State) error {
+ statefile := operation.NewStateFile(opsFile)
+ if state.Kind == operation.Install || state.Kind == operation.RunHook && state.Hook.Kind == hooks.Install {
+ state.Installed = false
@wallyworld

wallyworld Aug 20, 2015

Owner

do we really need this line?
why not just write out the file if Installed is false and it should be true?

+ "github.com/juju/juju/worker/uniter/operation"
+)
+
+func (s *upgradeStateContextSuite) TestInstalledBooleanFalseIfInstalling(c *gc.C) {
@wallyworld

wallyworld Aug 20, 2015

Owner

this doesn't check both conditions from the code

@mattyw mattyw changed the title from WIP: uniter/upgrade: Added steps for setting installed to uniter/upgrade: Added steps for setting installed Aug 20, 2015

wallyworld added a commit that referenced this pull request Aug 20, 2015

Merge pull request #31 from mattyw/install-bool-upgrade-step
uniter/upgrade: Added steps for setting installed

@wallyworld wallyworld merged commit 6c6cf22 into wallyworld:uniter-solver Aug 20, 2015

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment