diff options
author | Maxime Devos <maximedevos@telenet.be> | 2022-12-20 14:39:15 +0100 |
---|---|---|
committer | Maxime Devos <maximedevos@telenet.be> | 2022-12-20 14:39:15 +0100 |
commit | 6b5ff8dac9913057c89bd94130be75456ca971a8 (patch) | |
tree | 7833745b4e6cffe87201df10f4a5f1922de279b1 | |
parent | 40a17ea4232c433d519a0fb495a263d5b0e255aa (diff) | |
download | gnunet-scheme-6b5ff8dac9913057c89bd94130be75456ca971a8.tar.gz gnunet-scheme-6b5ff8dac9913057c89bd94130be75456ca971a8.zip |
fs/network: Fix argument order of 'construct-request-loc-signature'.
Now it is compatible with 'analyse-request-loc-signature', making the
test "analyse + construct round-trips (request-loc-signature)" pass.
* gnu/gnunet/fs/network.scm: Switch 'file-length' and
'content-hash-key'.
* tests/file-sharing.scm
("analyse + construct round-trips (request-loc-signature)"): Unskip.
-rw-r--r-- | gnu/gnunet/fs/network.scm | 3 | ||||
-rw-r--r-- | tests/file-sharing.scm | 4 |
2 files changed, 4 insertions, 3 deletions
diff --git a/gnu/gnunet/fs/network.scm b/gnu/gnunet/fs/network.scm index 97a66ab..3519aae 100644 --- a/gnu/gnunet/fs/network.scm +++ b/gnu/gnunet/fs/network.scm | |||
@@ -42,7 +42,8 @@ | |||
42 | ;; (see gnunet-signatures/gnunet_signatures.rst) | 42 | ;; (see gnunet-signatures/gnunet_signatures.rst) |
43 | (define %purpose-peer-placement 5) | 43 | (define %purpose-peer-placement 5) |
44 | 44 | ||
45 | (define* (construct-request-loc-signature content-hash-key file-length | 45 | (define* (construct-request-loc-signature file-length |
46 | content-hash-key | ||
46 | expiration-time | 47 | expiration-time |
47 | #:key | 48 | #:key |
48 | (purpose %purpose-peer-placement)) | 49 | (purpose %purpose-peer-placement)) |
diff --git a/tests/file-sharing.scm b/tests/file-sharing.scm index 0f9947c..fc3839e 100644 --- a/tests/file-sharing.scm +++ b/tests/file-sharing.scm | |||
@@ -46,12 +46,12 @@ | |||
46 | (define $file-length $natural) ; TODO bounds | 46 | (define $file-length $natural) ; TODO bounds |
47 | (define $purpose $natural) ; TODO bounds | 47 | (define $purpose $natural) ; TODO bounds |
48 | (define $expiration-time $natural) ; TODO bounds | 48 | (define $expiration-time $natural) ; TODO bounds |
49 | (test-expect-fail 1) | 49 | |
50 | (test-roundtrip "analyse + construct round-trips (request-loc-signature)" | 50 | (test-roundtrip "analyse + construct round-trips (request-loc-signature)" |
51 | analyse-request-loc-signature construct-request-loc-signature* | 51 | analyse-request-loc-signature construct-request-loc-signature* |
52 | normalise | 52 | normalise |
53 | (content-hash-key $content-hash-key) | ||
54 | (file-length $file-length) | 53 | (file-length $file-length) |
54 | (content-hash-key $content-hash-key) | ||
55 | (expiration-time $expiration-time) | 55 | (expiration-time $expiration-time) |
56 | (purpose $purpose)) | 56 | (purpose $purpose)) |
57 | 57 | ||