mirror of
https://gitlab.archlinux.org/archlinux/aurweb.git
synced 2025-02-03 10:43:03 +01:00
fix(test): correct test for ssh-key parsing
Our set of keys returned by "util.parse_ssh_keys" is unordered so we
have to adapt our test to not rely on a specific order for multiple keys.
Fixes: 5ccfa7c0fd
("fix: same ssh key entered multiple times")
Signed-off-by: moson <moson@archlinux.org>
This commit is contained in:
parent
5ccfa7c0fd
commit
c0bbe21d81
1 changed files with 2 additions and 5 deletions
|
@ -142,11 +142,8 @@ def assert_multiple_keys(pks):
|
||||||
keys = util.parse_ssh_keys(pks)
|
keys = util.parse_ssh_keys(pks)
|
||||||
assert len(keys) == 2
|
assert len(keys) == 2
|
||||||
pfx1, key1, pfx2, key2 = pks.split()
|
pfx1, key1, pfx2, key2 = pks.split()
|
||||||
k1, k2 = keys
|
assert (pfx1, key1) in keys
|
||||||
assert pfx1 == k1[0]
|
assert (pfx2, key2) in keys
|
||||||
assert key1 == k1[1]
|
|
||||||
assert pfx2 == k2[0]
|
|
||||||
assert key2 == k2[1]
|
|
||||||
|
|
||||||
|
|
||||||
def test_hash_query():
|
def test_hash_query():
|
||||||
|
|
Loading…
Add table
Reference in a new issue