diff --git a/spacy/cli/info.py b/spacy/cli/info.py index 36c3c063d..19a380eb9 100644 --- a/spacy/cli/info.py +++ b/spacy/cli/info.py @@ -19,7 +19,7 @@ def info_cli( # fmt: on ): """ - Print info about spaCy installation. If a pipeline is speficied as an argument, + Print info about spaCy installation. If a pipeline is specified as an argument, print its meta information. Flag --markdown prints details in Markdown for easy copy-pasting to GitHub issues. diff --git a/spacy/tests/test_cli.py b/spacy/tests/test_cli.py index 59c2e14ec..9661e54ce 100644 --- a/spacy/tests/test_cli.py +++ b/spacy/tests/test_cli.py @@ -13,6 +13,19 @@ import srsly import os from .util import make_tempdir +from .. import info +from ..lang.nl import Dutch + + +def test_cli_info(): + nlp = Dutch() + nlp.add_pipe("textcat") + with make_tempdir() as tmp_dir: + nlp.to_disk(tmp_dir) + raw_data = info(tmp_dir, exclude=[""]) + assert raw_data["lang"] == "nl" + assert raw_data["components"] == ["textcat"] + assert raw_data["source"] == str(tmp_dir) def test_cli_converters_conllu_to_docs():