about summary refs log tree commit diff
path: root/tests
diff options
context:
space:
mode:
authorArun Isaac2026-08-14 14:41:22 +0100
committerArun Isaac2026-08-14 16:00:27 +0100
commitc11d1286141f368e7e12601234d40ab63b0b9ab8 (patch)
treeb91ea95f2a9dd80386656390e321985ef8a713b6 /tests
parentf90d7190d007b56ff9bfbf65e73d5e86e5abfbcf (diff)
downloaddomagi-c11d1286141f368e7e12601234d40ab63b0b9ab8.tar.gz
domagi-c11d1286141f368e7e12601234d40ab63b0b9ab8.tar.lz
domagi-c11d1286141f368e7e12601234d40ab63b0b9ab8.zip
Test paths --fasta.
Diffstat (limited to 'tests')
-rw-r--r--tests/test_domagi.py22
1 files changed, 22 insertions, 0 deletions
diff --git a/tests/test_domagi.py b/tests/test_domagi.py
index 73897cf..4af8c37 100644
--- a/tests/test_domagi.py
+++ b/tests/test_domagi.py
@@ -207,6 +207,28 @@ def test_domagi_paths(tmp_path, test_data_file, expected_output):
                                    header=None),
                        check_dtype=False)
 
+@pytest.mark.xfail
+@pytest.mark.parametrize("test_data_file, expected_output",
+                         [(Path("test-data/test1.gfa"),
+                           Path("test-data/expected-output/test1.fa")),
+                          (Path("test-data/test2.gfa"),
+                           Path("test-data/expected-output/test2.fa")),
+                          (Path("test-data/test3.gfa"),
+                           Path("test-data/expected-output/test3.fa"))])
+def test_domagi_paths_fasta(tmp_path, test_data_file, expected_output):
+    duckdb_path = tmp_path / f"{test_data_file.stem}.db"
+    runner = CliRunner()
+    result = runner.invoke(main, ["build",
+                                  "--gfa", test_data_file,
+                                  "--out", duckdb_path])
+    assert result.exit_code == 0
+    result = runner.invoke(main, ["paths",
+                                  "--fasta",
+                                  "--db", duckdb_path])
+    assert result.exit_code == 0
+    with open(expected_output) as file:
+        assert result.stdout == file.read()
+
 @pytest.mark.parametrize("test_data_file, expected_output",
                          [(Path("test-data/test1.gfa"),
                            Path("test-data/expected-output/test1-stats")),