opencog / link-grammar

The CMU Link Grammar natural language parser
GNU Lesser General Public License v2.1
387 stars 118 forks source link

Moving the Python test suite to another directory #803

Open ampli opened 6 years ago

ampli commented 6 years ago

In PR #795 @linas wrote:

The python-examples directory is getting crowded. Perhaps there should be a python-tests directory, either in bindings or in the main tests directory? When the tests were simple, they made for good "examples"; now that they're complicated, I fear that they mostly confuse the reader, and serve to hide the simplest example(s).

I'm for putting it under the tests directory.

The name python-tests seems to me less appropriate, but I'm not sure I have a better one. I thought calling it api because it tests the library API. But it is also a test of the Python bindings, which api doesn't reflect. But maybe 'api' is fine after all because the Python bindings is also an LG library API by itself.

I am in the process of writing a test-suite for link-parser (using the scripttest Python framework for testing command-line applications). This can also be put under tests. Maybe under a directory link-parser (I would prefer not repeating an existing directory name, so maybe 'command-line`- supposing we are not going to have an additional command-line app...).

linas commented 6 years ago

The following directories would make sense, to me:

tests/python
tests/link-parser
tests/api

where tests/api would hold the existing C++ tests.