TestSuite vs "test discover"
Question: Is there any difference between creating a TestSuite and add to it all the
TestCases, or just running `python -m unittest discover` in the TestCases
directory?

For example, for a directory with two TestCases: `test_case_1.py` and
`test_case_2.py`:

    
    
    import unittest
    
    from test_case_1 import TestCaseClass as test1
    from test_case_2 import TestCaseClass as test2
    
    
    suite = unittest.TestSuite()
    suite.addTest(unittest.makeSuite(test1))
    suite.addTest(unittest.makeSuite(test2))
    
    unittest.TextTestRunner().run(suite)
    

Or just `cd` into that directory and run `python -m unittest discover`.

I'm getting the same result with either way, but I'm interesting in knowing
whether one way is preferred over the other, and why.


Answer: I think an obvious benefit in favor of `discover` is maintenance.

  * After a month, you get rid of `test_case_2` \- some of your code above will fail (the `import`) and you'll have to correct your above script. That's annoying, but not the end of the world. 

  * After two months, someone on your team made `test_case_3`, but was unaware that they need to add it to the script above. No tests fail, and everyone is happy - the problem is, nothing from `test_case_3` actually runs. However, you might counter that it's unreasonable to write new tests, and not notice that they're not running. This brings to the next scenario.

  * Even worse - after three months, someone merges two versions of your above script, and `test_case_3` gets squeezed out again. This might go unnoticed. Until it's corrected, people can work all they want on the stuff that `test_case_3` is supposed to check, but it's just untested.

