2 Commits 2f3c4c9d46 ... 642ba787dc

Author SHA1 Message Date
  Fabian Peter Hammerle 642ba787dc tests: rename digraph.gz -> digraph.dot 4 years ago
  Fabian Peter Hammerle 23470060ac readme: added plot cmd 4 years ago
3 changed files with 10 additions and 3 deletions
  1. 9 2
      README.md
  2. 1 1
      tests/cli/_dot_test.py
  3. 0 0
      tests/persons/digraph.dot

+ 9 - 2
README.md

@@ -22,7 +22,7 @@ $ pip3 install --user --upgrade yamily[yaml,graphviz]
 ... birth_date: 2019-12-23
 ... mother: !person
 ...   identifier: alice-mother
-...   name: Carol Test 
+...   name: Carol Test
 ...   birth_date: 1992-10-26
 ... father: !person
 ...   identifier: bob
@@ -49,7 +49,7 @@ Person(alice-mother, Carol Test, *1992-10-26)
 >>> carol_yaml = '''
 ... !person
 ... identifier: carol
-... name: Carol Test 
+... name: Carol Test
 ... birth_date: 1992-10-26
 ... '''
 >>> collection = yamily.PersonCollection()
@@ -90,6 +90,13 @@ name: Alice Test
 
 ```
 
+### Plot Family Tree
+
+```sh
+$ yamily-dot . > tree.dot
+$ dot -Tpdf -O tree.dot
+```
+
 ## Develop
 
 ```sh

+ 1 - 1
tests/cli/_dot_test.py

@@ -26,4 +26,4 @@ def test__dot_recurse_dir(capsys):
     _dot()
     out, err = capsys.readouterr()
     assert not err
-    assert out == pathlib.Path("persons").joinpath("digraph.gz").read_text()
+    assert out == pathlib.Path("persons").joinpath("digraph.dot").read_text()

+ 0 - 0
tests/persons/digraph.gz → tests/persons/digraph.dot