From 248a6cdde9e987608121d5d678ffda88c9e2ef5a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Reynir=20Bj=C3=B6rnsson?= Date: Fri, 25 Oct 2024 11:02:10 +0200 Subject: [PATCH 1/2] Partially fix tests Since mgit is not a public executable it will not be present in $PATH - so we must use %{exe:...} over %{bin:...}. The fix is partial because the (enabled_if ...) stanza doesn't work correctly for me at least. --- test/dune | 4 ++-- test/fold.t | 6 +++--- test/simple.t | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/test/dune b/test/dune index e5b7386..06f2bd6 100644 --- a/test/dune +++ b/test/dune @@ -3,14 +3,14 @@ (applies_to simple) (locks p9418) (enabled_if (= "true" {%read:git-daemon})) - (deps %{bin:mgit})) + (deps %{exe:../app/mgit.exe})) (cram (package git-kv) (applies_to fold) (locks p9418) (enabled_if (= "true" {%read:git-daemon})) - (deps %{bin:mgit})) + (deps %{exe:../app/mgit.exe})) (executable (name git_daemon_exists) diff --git a/test/fold.t b/test/fold.t index 73cee83..5e8b846 100644 --- a/test/fold.t +++ b/test/fold.t @@ -11,14 +11,14 @@ Batch operation > exists /bar > quit > quit - /"bar" does not exists + /bar does not exists $ mgit git://localhost/simple#main < list / > get /bar > get /foo > quit - - bar - - foo + - /bar + - /foo 00000000: 4769 7420 726f 636b 7321 Git rocks! 00000000: 4865 6c6c 6f20 576f 726c 6421 Hello World! $ cd simple diff --git a/test/simple.t b/test/simple.t index b32c465..ff2c22e 100644 --- a/test/simple.t +++ b/test/simple.t @@ -35,7 +35,7 @@ Simple test of our Git Key-Value store > get /bar > get /foo > quit - + /"bar" + + /bar * / 00000000: 4769 7420 726f 636b 7321 0a Git rocks!. 00000000: 4865 6c6c 6f20 576f 726c 6421 0a Hello World!. From 23de4011847247c39eb4e303fb627be0010bb3c2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Reynir=20Bj=C3=B6rnsson?= Date: Fri, 25 Oct 2024 11:40:21 +0200 Subject: [PATCH 2/2] Remove broken (enabled_if ..) stanza --- test/dune | 2 -- 1 file changed, 2 deletions(-) diff --git a/test/dune b/test/dune index 06f2bd6..1c0a228 100644 --- a/test/dune +++ b/test/dune @@ -2,14 +2,12 @@ (package git-kv) (applies_to simple) (locks p9418) - (enabled_if (= "true" {%read:git-daemon})) (deps %{exe:../app/mgit.exe})) (cram (package git-kv) (applies_to fold) (locks p9418) - (enabled_if (= "true" {%read:git-daemon})) (deps %{exe:../app/mgit.exe})) (executable