Python Programming: Write a program using unittest.TestCase methods to confirm that the addition and subtraction of date and timedelta objects produce correct results. Important notes: Use the unittest module to create a TestCase to test that the addition and subtraction of date and timedelta objects produce correct results... For example I could create a TestCase with a function that tests the addition of date and timedelta objects; a function that tests the subtraction of date and timedelta and then call unittest's main method at the end. When you run this program, it should tell us whether the text was successful or not. See attached image for what the output should look like.
Python
Write a program using unittest.TestCase methods to confirm that the addition and subtraction of date and timedelta objects produce correct results.
Important notes:
Use the unittest module to create a TestCase to test that the addition and subtraction of date and timedelta objects produce correct results... For example I could create a TestCase with a function that tests the addition of date and timedelta objects; a function that tests the subtraction of date and timedelta and then call unittest's main method at the end.
When you run this program, it should tell us whether the text was successful or not. See attached image for what the output should look like.
Trending now
This is a popular solution!
Step by step
Solved in 2 steps