User Tools

Site Tools


PyCharm - IDE from JetBrains

We have been so lucky to receive license an open source license for NAV that contributors are free to use! Contact Morten Brekkevold for details if you have contributed to NAV to receive a copy of the license.

Setting up to unit tests and run em automagically on code change

In the run configuration (nav-bar, left for the green RUN arrow), click edit run configurations):

  • Top left, + sign for adding a new run configuration
  • Select “Python's test” and “py.test” in the tree-view on the left side bar.

Run configuration options should be the following:

  • Target: $NAV-ROOT/python/
  • Options: ticked and text box should contain: ../tests/unittests
  • Working directory: $NAV-ROOT/python
  • Click apply and save.

NAV UNITTESTS run configuration should now be available from the drop down of various run configurations.

Run it once .. a panel pane at the bottom screen panel pops up and it starts looking for tests and running em.
Ignore output saying Empty test suite, that's just test cases which contains no unit tests so no worries.
BUT to the left at this bottom screen panel, below the green double arrow, CHECK IT. (tooltip says: toggle automatic rerun of tests on code change)

Be a happy hacker practicing TDD!

Note 1: Bottom screen panel can be toggled by clicking in bottom left corner! :-)
Note 2: Yes, it will run your tests, maybe not right after you click SAVE, but soon after.

Setting up PyLint

$FileDirRelativeToSourcepath$/$FileName$ –rcfile=pylint.rc –disable=I

devel/pycharm.txt · Last modified: 2012/06/21 15:22 by norangshol