Merge lp:~gocept/landscape-client/py3-package-skeleton into lp:~landscape/landscape-client/trunk

Proposed by Steffen Allner
Status: Merged
Approved by: Данило Шеган
Approved revision: 989
Merged at revision: 967
Proposed branch: lp:~gocept/landscape-client/py3-package-skeleton
Merge into: lp:~landscape/landscape-client/trunk
Diff against target: 34 lines (+6/-5)
2 files modified
landscape/package/tests/helpers.py (+5/-5)
py3_ready_tests (+1/-0)
To merge this branch: bzr merge lp:~gocept/landscape-client/py3-package-skeleton
Reviewer Review Type Date Requested Status
🤖 Landscape Builder test results Approve
Данило Шеган (community) Approve
Daniel Havlik (community) Approve
Review via email: mp+320610@code.launchpad.net

Commit message

Declare hashes as bytestrings in landscape/package/tests/helpers.py to make landscape.package.skeleton tests pass with py3.

Description of the change

This MP considers the tests for landscape.package.skeleton, which were mainly broken because of hashes not explicitly being declared as bytes.

To post a comment you must log in.
Revision history for this message
🤖 Landscape Builder (landscape-builder) :
review: Abstain (executing tests)
Revision history for this message
Steffen Allner (sallner) wrote :

When executing the tests with my locale another error occured, which is mainly the different behaviour of apt.chache.Chache, which returns better decoded package.candidate.description

see:
http://paste.ubuntu.com/24227615/

Is this intended behaviour? Then I should maybe switch also to LC_ALL=C for all tests on my machine.

Revision history for this message
🤖 Landscape Builder (landscape-builder) wrote :

Command: TRIAL_ARGS=-j4 make check
Result: Success
Revno: 988
Branch: lp:~gocept/landscape-client/py3-package-skeleton
Jenkins: https://ci.lscape.net/job/latch-test-xenial/3696/

review: Approve (test results)
Revision history for this message
Daniel Havlik (nilo) wrote :

Diff: +1

I can't see a relation of the question above about the locale and this change. This should be sorted out seperately.

review: Approve
Revision history for this message
Данило Шеган (danilo) wrote :

Right: tests should not be locale dependent (it indicates a problem with what type of strings are being passed around somewhere, iow, code or tests are not deterministic), but you can fix that in a separate branch.

Please make sure to create a card for it in the trello board.

review: Approve
Revision history for this message
🤖 Landscape Builder (landscape-builder) wrote :

Attempt to merge into lp:landscape-client failed due to conflicts:

text conflict in py3_ready_tests

989. By Steffen Allner

Backmerge from trunk.

Revision history for this message
Steffen Allner (sallner) wrote :

Resolved the conflict.

Revision history for this message
🤖 Landscape Builder (landscape-builder) :
review: Abstain (executing tests)
Revision history for this message
🤖 Landscape Builder (landscape-builder) wrote :

Command: TRIAL_ARGS=-j4 make check
Result: Success
Revno: 989
Branch: lp:~gocept/landscape-client/py3-package-skeleton
Jenkins: https://ci.lscape.net/job/latch-test-xenial/3698/

review: Approve (test results)

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'landscape/package/tests/helpers.py'
--- landscape/package/tests/helpers.py 2017-03-21 12:43:13 +0000
+++ landscape/package/tests/helpers.py 2017-03-22 12:34:23 +0000
@@ -320,15 +320,15 @@
320HASH1 = base64.decodestring(b"/ezv4AefpJJ8DuYFSq4RiEHJYP4=")320HASH1 = base64.decodestring(b"/ezv4AefpJJ8DuYFSq4RiEHJYP4=")
321HASH2 = base64.decodestring(b"glP4DwWOfMULm0AkRXYsH/exehc=")321HASH2 = base64.decodestring(b"glP4DwWOfMULm0AkRXYsH/exehc=")
322HASH3 = base64.decodestring(b"NJM05mj86veaSInYxxqL1wahods=")322HASH3 = base64.decodestring(b"NJM05mj86veaSInYxxqL1wahods=")
323HASH_MINIMAL = "6\xce\x8f\x1bM\x82MWZ\x1a\xffjAc(\xdb(\xa1\x0eG"323HASH_MINIMAL = b"6\xce\x8f\x1bM\x82MWZ\x1a\xffjAc(\xdb(\xa1\x0eG"
324HASH_SIMPLE_RELATIONS = (324HASH_SIMPLE_RELATIONS = (
325 "'#\xab&k\xe6\xf5E\xcfB\x9b\xceO7\xe6\xec\xa9\xddY\xaa")325 b"'#\xab&k\xe6\xf5E\xcfB\x9b\xceO7\xe6\xec\xa9\xddY\xaa")
326HASH_VERSION_RELATIONS = (326HASH_VERSION_RELATIONS = (
327 '\x84\xc9\xb4\xb3\r\x95\x16\x03\x95\x98\xc0\x14u\x06\xf7eA\xe65\xd1')327 b"\x84\xc9\xb4\xb3\r\x95\x16\x03\x95\x98\xc0\x14u\x06\xf7eA\xe65\xd1")
328HASH_MULTIPLE_RELATIONS = (328HASH_MULTIPLE_RELATIONS = (
329 '\xec\xcdi\xdc\xde-\r\xc3\xd3\xc9s\x84\xe4\xc3\xd6\xc4\x12T\xa6\x0e')329 b"\xec\xcdi\xdc\xde-\r\xc3\xd3\xc9s\x84\xe4\xc3\xd6\xc4\x12T\xa6\x0e")
330HASH_OR_RELATIONS = (330HASH_OR_RELATIONS = (
331 '\xa1q\xf4*\x1c\xd4L\xa1\xca\xf1\xfa?\xc3\xc7\x9f\x88\xd53B\xc9')331 b"\xa1q\xf4*\x1c\xd4L\xa1\xca\xf1\xfa?\xc3\xc7\x9f\x88\xd53B\xc9")
332332
333333
334def create_deb(target_dir, pkg_name, pkg_data):334def create_deb(target_dir, pkg_name, pkg_data):
335335
=== modified file 'py3_ready_tests'
--- py3_ready_tests 2017-03-22 08:24:47 +0000
+++ py3_ready_tests 2017-03-22 12:34:23 +0000
@@ -3,5 +3,6 @@
3landscape.package.tests.test_store3landscape.package.tests.test_store
4landscape.package.tests.test_reporter4landscape.package.tests.test_reporter
55
6landscape.package.tests.test_skeleton
6landscape.package.tests.test_taskhandler7landscape.package.tests.test_taskhandler
78

Subscribers

People subscribed via source and target branches

to all changes: