Merge lp:~elopio/snappy/wait-boot-ok into lp:~snappy-dev/snappy/snappy-moved-to-github

Proposed by Leo Arias
Status: Merged
Approved by: Leo Arias
Approved revision: 730
Merged at revision: 730
Proposed branch: lp:~elopio/snappy/wait-boot-ok
Merge into: lp:~snappy-dev/snappy/snappy-moved-to-github
Diff against target: 67 lines (+10/-4)
3 files modified
_integration-tests/tests/rollback_test.go (+5/-0)
_integration-tests/testutils/partition/bootloader.go (+4/-3)
_integration-tests/testutils/partition/bootloader_test.go (+1/-1)
To merge this branch: bzr merge lp:~elopio/snappy/wait-boot-ok
Reviewer Review Type Date Requested Status
Federico Gimenez (community) Approve
Review via email: mp+272992@code.launchpad.net

Commit message

On the rollback tests, wait for boot-ok to run. Workaround for bug #1498293.

To post a comment you must log in.
Revision history for this message
Federico Gimenez (fgimenez) wrote :

Very nice Leo, thanks!

review: Approve
Revision history for this message
Snappy Tarmac (snappydevtarmac) wrote :

The attempt to merge lp:~elopio/snappy/wait-boot-ok into lp:snappy failed. Below is the output from the failed tests.

Checking docs
Checking formatting
Formatting wrong in following files
_integration-tests/tests/rollback_test.go

# we always run in a fresh dir in tarmac
export GOPATH=$(mktemp -d)
trap 'rm -rf "$GOPATH"' EXIT

# this is a hack, but not sure tarmac is golang friendly
mkdir -p $GOPATH/src/launchpad.net/snappy
cp -a . $GOPATH/src/launchpad.net/snappy/
cd $GOPATH/src/launchpad.net/snappy

sh -v ./run-checks
#!/bin/sh

set -eu

if which goctest >/dev/null; then
    goctest="goctest"
else
    goctest="go test"
fi

QUICK=""
if [ "${1:-}" = "--quick" ]; then
    QUICK=yes
fi

echo Checking docs
./mdlint.py docs/*.md

echo Checking formatting
fmt=$(gofmt -l .)

if [ -n "$fmt" ]; then
    echo "Formatting wrong in following files"
    echo "$fmt"
    exit 1
fi

Revision history for this message
Snappy Tarmac (snappydevtarmac) wrote :
Download full text (11.4 KiB)

The attempt to merge lp:~elopio/snappy/wait-boot-ok into lp:snappy failed. Below is the output from the failed tests.

Checking docs
Checking formatting
Installing godeps
Install golint
Obtaining dependencies
update github.com/cheggaaa/pb failed; trying to fetch newer version
update github.com/mvo5/uboot-go failed; trying to fetch newer version
github.com/cheggaaa/pb now at e8c7cc515bfde3e267957a3b110080ceed51354e
update golang.org/x/crypto failed; trying to fetch newer version
github.com/mvo5/uboot-go now at 361f6ebcbb54f389d15dc9faefa000e996ba3e37
update github.com/gorilla/mux failed; trying to fetch newer version
golang.org/x/crypto now at 60052bd85f2d91293457e8811b0cf26b773de469
update github.com/gosexy/gettext failed; trying to fetch newer version
github.com/gorilla/mux now at ee1815431e497d3850809578c93ab6705f1a19f7
update github.com/mvo5/goconfigparser failed; trying to fetch newer version
github.com/gosexy/gettext now at 98b7b91596d20b96909e6b60d57411547dd9959c
update github.com/peterh/liner failed; trying to fetch newer version
github.com/mvo5/goconfigparser now at 26426272dda20cc76aa1fa44286dc743d2972fe8
update code.google.com/p/go.crypto failed; trying to fetch newer version
github.com/peterh/liner now at 1bb0d1c1a25ed393d8feb09bab039b2b1b1fbced
update github.com/blakesmith/ar failed; trying to fetch newer version
code.google.com/p/go.crypto now at 69e2a90ed92d03812364aeb947b7068dc42e561e
update github.com/coreos/go-systemd failed; trying to fetch newer version
github.com/blakesmith/ar now at c9a977dd0cc1392b023382c7bfa5a22af8d3b730
update github.com/gorilla/context failed; trying to fetch newer version
github.com/coreos/go-systemd now at f743bc15d6bddd23662280b4ad20f7c874cdd5ad
update github.com/jessevdk/go-flags failed; trying to fetch newer version
github.com/gorilla/context now at 1c83b3eabd45b6d76072b66b746c20815fb2872d
update gopkg.in/check.v1 failed; trying to fetch newer version
github.com/jessevdk/go-flags now at 1acbbaff2f347c412a0c7884873bd72cc9c1f5b4
update gopkg.in/yaml.v2 failed; trying to fetch newer version
gopkg.in/check.v1 now at 64131543e7896d5bcc6bd5a76287eb75ea96c673
update gopkg.in/tomb.v2 failed; trying to fetch newer version
gopkg.in/yaml.v2 now at 49c95bdc21843256fb6c4e0d370a05f24a0bf213
gopkg.in/tomb.v2 now at 14b3d72120e8d10ea6e6b7f87f7175734b1faab8
Building
Running tests from /tmp/tmp.8InWSzIOeo/src/launchpad.net/snappy
=== RUN Test
OK: 18 passed
--- PASS: Test (0.35 seconds)
PASS
coverage: 74.8% of statements
ok launchpad.net/snappy/clickdeb 0.356s coverage: 74.8% of statements
? launchpad.net/snappy/cmd/snapd [no test files]
=== RUN Test
2015/10/01 14:52:18.472171 common.go:40: PANIC can not set option description for "package name"
OK: 12 passed
--- PASS: Test (0.09 seconds)
PASS
coverage: 20.9% of statements
ok launchpad.net/snappy/cmd/snappy 0.101s coverage: 20.9% of statements
=== RUN Test
OK: 41 passed
--- PASS: Test (0.11 seconds)
PASS
coverage: 89.7% of statements
ok launchpad.net/snappy/coreconfig 0.126s coverage: 89.7% of statements
=== RUN Test
OK: 26 passed
--- PASS: Test (0.11 seconds)
PASS
coverage: 68.1% of statements
ok launchpad.net/snappy/daemon 0.125s coverage: 68.1% of sta...

Revision history for this message
Snappy Tarmac (snappydevtarmac) wrote :
Download full text (11.4 KiB)

The attempt to merge lp:~elopio/snappy/wait-boot-ok into lp:snappy failed. Below is the output from the failed tests.

Checking docs
Checking formatting
Installing godeps
Install golint
Obtaining dependencies
update github.com/blakesmith/ar failed; trying to fetch newer version
update github.com/coreos/go-systemd failed; trying to fetch newer version
github.com/blakesmith/ar now at c9a977dd0cc1392b023382c7bfa5a22af8d3b730
update github.com/gorilla/context failed; trying to fetch newer version
github.com/coreos/go-systemd now at f743bc15d6bddd23662280b4ad20f7c874cdd5ad
update github.com/jessevdk/go-flags failed; trying to fetch newer version
github.com/gorilla/context now at 1c83b3eabd45b6d76072b66b746c20815fb2872d
update gopkg.in/check.v1 failed; trying to fetch newer version
github.com/jessevdk/go-flags now at 1acbbaff2f347c412a0c7884873bd72cc9c1f5b4
update gopkg.in/yaml.v2 failed; trying to fetch newer version
gopkg.in/check.v1 now at 64131543e7896d5bcc6bd5a76287eb75ea96c673
update gopkg.in/tomb.v2 failed; trying to fetch newer version
gopkg.in/yaml.v2 now at 49c95bdc21843256fb6c4e0d370a05f24a0bf213
update github.com/cheggaaa/pb failed; trying to fetch newer version
gopkg.in/tomb.v2 now at 14b3d72120e8d10ea6e6b7f87f7175734b1faab8
update github.com/mvo5/uboot-go failed; trying to fetch newer version
github.com/cheggaaa/pb now at e8c7cc515bfde3e267957a3b110080ceed51354e
update golang.org/x/crypto failed; trying to fetch newer version
github.com/mvo5/uboot-go now at 361f6ebcbb54f389d15dc9faefa000e996ba3e37
update github.com/gorilla/mux failed; trying to fetch newer version
golang.org/x/crypto now at 60052bd85f2d91293457e8811b0cf26b773de469
update github.com/gosexy/gettext failed; trying to fetch newer version
github.com/gorilla/mux now at ee1815431e497d3850809578c93ab6705f1a19f7
update github.com/mvo5/goconfigparser failed; trying to fetch newer version
github.com/gosexy/gettext now at 98b7b91596d20b96909e6b60d57411547dd9959c
update github.com/peterh/liner failed; trying to fetch newer version
github.com/mvo5/goconfigparser now at 26426272dda20cc76aa1fa44286dc743d2972fe8
update code.google.com/p/go.crypto failed; trying to fetch newer version
github.com/peterh/liner now at 1bb0d1c1a25ed393d8feb09bab039b2b1b1fbced
code.google.com/p/go.crypto now at 69e2a90ed92d03812364aeb947b7068dc42e561e
Building
Running tests from /tmp/tmp.IdgwDiOjba/src/launchpad.net/snappy
=== RUN Test
OK: 18 passed
--- PASS: Test (0.38 seconds)
PASS
coverage: 75.2% of statements
ok launchpad.net/snappy/clickdeb 0.387s coverage: 75.2% of statements
? launchpad.net/snappy/cmd/snapd [no test files]
=== RUN Test
2015/10/01 15:12:12.007522 common.go:40: PANIC can not set option description for "package name"
OK: 12 passed
--- PASS: Test (0.07 seconds)
PASS
coverage: 20.9% of statements
ok launchpad.net/snappy/cmd/snappy 0.102s coverage: 20.9% of statements
=== RUN Test
OK: 41 passed
--- PASS: Test (0.11 seconds)
PASS
coverage: 89.7% of statements
ok launchpad.net/snappy/coreconfig 0.112s coverage: 89.7% of statements
=== RUN Test
OK: 26 passed
--- PASS: Test (0.10 seconds)
PASS
coverage: 68.1% of statements
ok launchpad.net/snappy/daemon 0.103s coverage: 68.1% of sta...

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file '_integration-tests/tests/rollback_test.go'
--- _integration-tests/tests/rollback_test.go 2015-07-30 09:07:31 +0000
+++ _integration-tests/tests/rollback_test.go 2015-10-01 15:12:45 +0000
@@ -23,6 +23,8 @@
23 "strconv"23 "strconv"
2424
25 . "launchpad.net/snappy/_integration-tests/testutils/common"25 . "launchpad.net/snappy/_integration-tests/testutils/common"
26 "launchpad.net/snappy/_integration-tests/testutils/partition"
27 "launchpad.net/snappy/_integration-tests/testutils/wait"
2628
27 check "gopkg.in/check.v1"29 check "gopkg.in/check.v1"
28)30)
@@ -39,6 +41,9 @@
39 Reboot(c)41 Reboot(c)
40 } else if CheckRebootMark(c.TestName()) {42 } else if CheckRebootMark(c.TestName()) {
41 RemoveRebootMark(c)43 RemoveRebootMark(c)
44 // Workaround for bug https://bugs.launchpad.net/snappy/+bug/1498293
45 // TODO remove once the bug is fixed. --elopio - 2015-09-30
46 wait.ForFunction(c, "regular", partition.Mode)
42 currentVersion := GetCurrentUbuntuCoreVersion(c)47 currentVersion := GetCurrentUbuntuCoreVersion(c)
43 c.Assert(currentVersion > GetSavedVersion(c), check.Equals, true)48 c.Assert(currentVersion > GetSavedVersion(c), check.Equals, true)
44 ExecCommand(c, "sudo", "snappy", "rollback", "ubuntu-core",49 ExecCommand(c, "sudo", "snappy", "rollback", "ubuntu-core",
4550
=== modified file '_integration-tests/testutils/partition/bootloader.go'
--- _integration-tests/testutils/partition/bootloader.go 2015-09-13 02:52:52 +0000
+++ _integration-tests/testutils/partition/bootloader.go 2015-10-01 15:12:45 +0000
@@ -69,7 +69,7 @@
69// config file. For uboot systems the boot config file does not change, so that69// config file. For uboot systems the boot config file does not change, so that
70// we take the other partition in that case70// we take the other partition in that case
71func NextBootPartition() (partition string, err error) {71func NextBootPartition() (partition string, err error) {
72 m, err := mode()72 m, err := Mode()
73 if err != nil {73 if err != nil {
74 return74 return
75 }75 }
@@ -96,7 +96,8 @@
96 return96 return
97}97}
9898
99func mode() (mode string, err error) {99// Mode returns the current bootloader mode, regular or try.
100func Mode() (mode string, err error) {
100 return confValue("snappy_mode")101 return confValue("snappy_mode")
101}102}
102103
@@ -144,7 +145,7 @@
144 if err != nil {145 if err != nil {
145 return146 return
146 }147 }
147 m, err := mode()148 m, err := Mode()
148 if err != nil {149 if err != nil {
149 return150 return
150 }151 }
151152
=== modified file '_integration-tests/testutils/partition/bootloader_test.go'
--- _integration-tests/testutils/partition/bootloader_test.go 2015-09-13 02:55:08 +0000
+++ _integration-tests/testutils/partition/bootloader_test.go 2015-10-01 15:12:45 +0000
@@ -244,7 +244,7 @@
244 return "test-system", nil244 return "test-system", nil
245 }245 }
246246
247 mode, err := mode()247 mode, err := Mode()
248248
249 c.Assert(err, check.IsNil, check.Commentf("Unexpected error %v", err))249 c.Assert(err, check.IsNil, check.Commentf("Unexpected error %v", err))
250 c.Assert(mode, check.Equals, "test_mode", check.Commentf("Wrong mode"))250 c.Assert(mode, check.Equals, "test_mode", check.Commentf("Wrong mode"))

Subscribers

People subscribed via source and target branches