Today in learning TestSuite test suite, a total of three test cases, the test suite TestSuite added only one, but the implementation of all three use cases.
Degree of your mother find out the reasons, turned out to be a configuration problem PyCharm.
pycharm把代码识别成了测试代码,所以没有执行if __name__ =='__main__':之后的代码。
1. Open: Run Run -> Edit configurations Structure Edit -> New Python + 1 arranged on it. (Do not Python tests)
2.Script add the path. Do not add directly to "OK", it should be also possible.
3. Re-run, should be on it. (Execution, you can see here, are not you just add configuration)