add spread test for wayland #3759

Merged
merged 11 commits into from Aug 28, 2017

Conversation

Projects
None yet
4 participants
Contributor

jdstrand commented Aug 17, 2017

No description provided.

codecov-io commented Aug 17, 2017

Codecov Report

Merging #3759 into master will increase coverage by <.01%.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #3759      +/-   ##
==========================================
+ Coverage   75.81%   75.81%   +<.01%     
==========================================
  Files         402      402              
  Lines       34783    34793      +10     
==========================================
+ Hits        26371    26380       +9     
- Misses       6539     6540       +1     
  Partials     1873     1873
Impacted Files Coverage Δ
cmd/snap/cmd_aliases.go 93.33% <0%> (-1.67%) ⬇️
overlord/snapstate/snapstate.go 80.4% <0%> (-0.27%) ⬇️
overlord/ifacestate/helpers.go 62.33% <0%> (ø) ⬆️
interfaces/sorting.go 98.71% <0%> (ø) ⬆️
dirs/dirs.go 97.91% <0%> (+0.24%) ⬆️
wrappers/binaries.go 79.54% <0%> (+6.81%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 789c8b4...729d2c9. Read the comment docs.

Minor comments inline

tests/main/interfaces-wayland/task.yaml
+prepare: |
+ . $TESTSLIB/pkgdb.sh
+ echo "Ensure we have a wayland compositor"
+ distro_install_package weston
@sergiocazzolato

sergiocazzolato Aug 17, 2017

Contributor

This should go in the pkgdb.sh script, we started to install all the dependencies in the project preparation a time ago.

@jdstrand

jdstrand Aug 18, 2017

Contributor

Done

tests/main/interfaces-wayland/task.yaml
+restore: |
+ . $TESTSLIB/pkgdb.sh
+ /usr/bin/killall -9 /usr/bin/weston || true
+ distro_auto_remove_packages weston
@sergiocazzolato

sergiocazzolato Aug 17, 2017

Contributor

this should not be needed.

@jdstrand

jdstrand Aug 18, 2017

Contributor

Done

jdstrand added some commits Aug 18, 2017

Contributor

jdstrand commented Aug 21, 2017

@sergiocazzolato - I made the requested changes. This should be ready for another review.

Contributor

jdstrand commented Aug 24, 2017

Note the zesty failure is unrelated:

Cloning into '/tmp/go/src/golang.org/x/net'...
fatal: unable to access 'https://go.googlesource.com/net/': gnutls_handshake() failed: The TLS connection was non-properly terminated.
package golang.org/x/net/context: exit status 128
autopkgtest [21:00:53]: test integrationtests: -----------------------]
autopkgtest [21:00:53]: test integrationtests:  - - - - - - - - - - results - - - - - - - - - -
integrationtests     FAIL non-zero exit status 1
autopkgtest [21:00:53]: @@@@@@@@@@@@@@@@@@@@ summary
integrationtests     FAIL non-zero exit status 1
Exit request sent.
Contributor

jdstrand commented Aug 24, 2017

@sergiocazzolato - can you take another look at this? It is passing and I addressed all your feedback.

tests/main/interfaces-wayland/task.yaml
+ . $TESTSLIB/pkgdb.sh
+ snap install --edge test-wayland
+
+restore: |
@sergiocazzolato

sergiocazzolato Aug 24, 2017

Contributor

This could be removed

@jdstrand

jdstrand Aug 24, 2017

Contributor

Done

Contributor

sergiocazzolato commented Aug 24, 2017

LGMT, thanks for the test!

Contributor

jdstrand commented Aug 24, 2017

Hmm, now the zesty-amd64 autopkgtest failed for this test, so I'll need to look at that.

mvo5 approved these changes Aug 25, 2017

Looks good, thanks for writing this test! Some small comments inside for your consideration.

tests/main/interfaces-wayland/task.yaml
+
+prepare: |
+ . $TESTSLIB/pkgdb.sh
+ snap install --edge test-wayland
@mvo5

mvo5 Aug 25, 2017

Collaborator

Our usual pattern for spread helpers is: test-snapd-*, i.e. test-snapd-wayland.

@jdstrand

jdstrand Aug 25, 2017

Contributor

Done

tests/main/interfaces-wayland/task.yaml
+ echo "Expected error with plug disconnected"
+
+ echo "Stop weston compositor"
+ /usr/bin/killall -9 /usr/bin/weston || true
@mvo5

mvo5 Aug 25, 2017

Collaborator

I think we want this also in restore: to ensure if anything fails during the test we do proper cleanup.

@jdstrand

jdstrand Aug 25, 2017

Contributor

Note the comment below:

# If this is in 'restore', it hangs the test
@jdstrand

jdstrand Aug 25, 2017

Contributor

I've decided to add the killall to restore but leave it at the end of execute to prevent the hang in the normal case.

jdstrand added some commits Aug 25, 2017

Contributor

jdstrand commented Aug 25, 2017

@mvo, ok, comments addressed. Thanks for the review :)

mvo5 approved these changes Aug 25, 2017

+
+prepare: |
+ . $TESTSLIB/pkgdb.sh
+ snap install --edge test-snapd-wayland
@mvo5

mvo5 Aug 25, 2017

Collaborator

One more thing - is test-snapd-wayland packaged somewhere? If there is a snapcraft.yaml for it, we should add it to tests/lib/snaps or if not add a comment where the git tree for this is.

@jdstrand

jdstrand Aug 25, 2017

Contributor

Yes, lp:~jdstrand/+git/test-snapd-wayland. I listed it in the description of the snap:

$ snap info test-snapd-wayland
name:      test-snapd-wayland
summary:   "Basic wayland test snap"
publisher: jdstrand
description: |
  Basic wayland test snap
  lp:~jdstrand/+git/test-snapd-wayland
...

@mvo5 mvo5 merged commit 3aa2420 into snapcore:master Aug 28, 2017

7 checks passed

artful-amd64 autopkgtest finished (success)
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
xenial-amd64 autopkgtest finished (success)
Details
xenial-i386 autopkgtest finished (success)
Details
xenial-ppc64el autopkgtest finished (success)
Details
yakkety-amd64 autopkgtest finished (success)
Details
zesty-amd64 autopkgtest finished (success)
Details

@jdstrand jdstrand deleted the jdstrand:wayland-spread branch Aug 29, 2017

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