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
1=== modified file 'landscape/package/tests/helpers.py'
2--- landscape/package/tests/helpers.py 2017-03-21 12:43:13 +0000
3+++ landscape/package/tests/helpers.py 2017-03-22 12:34:23 +0000
4@@ -320,15 +320,15 @@
5 HASH1 = base64.decodestring(b"/ezv4AefpJJ8DuYFSq4RiEHJYP4=")
6 HASH2 = base64.decodestring(b"glP4DwWOfMULm0AkRXYsH/exehc=")
7 HASH3 = base64.decodestring(b"NJM05mj86veaSInYxxqL1wahods=")
8-HASH_MINIMAL = "6\xce\x8f\x1bM\x82MWZ\x1a\xffjAc(\xdb(\xa1\x0eG"
9+HASH_MINIMAL = b"6\xce\x8f\x1bM\x82MWZ\x1a\xffjAc(\xdb(\xa1\x0eG"
10 HASH_SIMPLE_RELATIONS = (
11- "'#\xab&k\xe6\xf5E\xcfB\x9b\xceO7\xe6\xec\xa9\xddY\xaa")
12+ b"'#\xab&k\xe6\xf5E\xcfB\x9b\xceO7\xe6\xec\xa9\xddY\xaa")
13 HASH_VERSION_RELATIONS = (
14- '\x84\xc9\xb4\xb3\r\x95\x16\x03\x95\x98\xc0\x14u\x06\xf7eA\xe65\xd1')
15+ b"\x84\xc9\xb4\xb3\r\x95\x16\x03\x95\x98\xc0\x14u\x06\xf7eA\xe65\xd1")
16 HASH_MULTIPLE_RELATIONS = (
17- '\xec\xcdi\xdc\xde-\r\xc3\xd3\xc9s\x84\xe4\xc3\xd6\xc4\x12T\xa6\x0e')
18+ b"\xec\xcdi\xdc\xde-\r\xc3\xd3\xc9s\x84\xe4\xc3\xd6\xc4\x12T\xa6\x0e")
19 HASH_OR_RELATIONS = (
20- '\xa1q\xf4*\x1c\xd4L\xa1\xca\xf1\xfa?\xc3\xc7\x9f\x88\xd53B\xc9')
21+ b"\xa1q\xf4*\x1c\xd4L\xa1\xca\xf1\xfa?\xc3\xc7\x9f\x88\xd53B\xc9")
22
23
24 def create_deb(target_dir, pkg_name, pkg_data):
25
26=== modified file 'py3_ready_tests'
27--- py3_ready_tests 2017-03-22 08:24:47 +0000
28+++ py3_ready_tests 2017-03-22 12:34:23 +0000
29@@ -3,5 +3,6 @@
30 landscape.package.tests.test_store
31 landscape.package.tests.test_reporter
32
33+landscape.package.tests.test_skeleton
34 landscape.package.tests.test_taskhandler
35

Subscribers

People subscribed via source and target branches

to all changes: