Create a file named test_unittest.py that contains a test class with two test methods
Sample test file using unittest framework. inc_dec is the file that's being tested:
import inc_dec # The code to test
import unittest # The test framework
class Test_TestIncrementDecrement(unittest.TestCase):
def test_increment(self):
self.assertEqual(inc_dec.increment(3), 4) # checks if the results is 4 when x = 3
def test_decrement(self):
self.assertEqual(inc_dec.decrement(3), 4)
if __name__ == '__main__':
unittest.main()















