bottom-up testing proceeds from lower-level components to higher-level components for examplebottom-level functionswhich do not invoke other functionsare tested firstfollowed by functions that call only bottom-level functionsand so on similarly class that does not depend upon any other classes can be tested before another class that depends on the former this form of testing is usually described as unit testingas the functionality of specific component is tested in isolation of the larger software project if used properlythis strategy better isolates the cause of errors to the component being testedas lower-level components upon which it relies should have already been thoroughly tested python provides several forms of support for automated testing when functions or classes are defined in moduletesting for that module can be embedded in the same file the mechanism for doing so was described in section code that is shielded in conditional construct of the form if name =__main__ perform tests will be executed when python is invoked directly on that modulebut not when the module is imported for use in larger software project it is common to put tests in such construct to test the functionality of the functions and classes specifically defined in that module more robust support for automation of unit testing is provided by python' unittest module this framework allows the grouping of individual test cases into larger test suitesand provides support for executing those suitesand reporting or analyzing the results of those tests as software is maintainedthe act of regression testing is usedwhereby all previous tests are re-executed to ensure that changes to the software do not introduce new bugs in previously tested components debugging the simplest debugging technique consists of using print statements to track the values of variables during the execution of the program problem with this approach is that eventually the print statements need to be removed or commented outso they are not executed when the software is finally released better approach is to run the program within debuggerwhich is specialized environment for controlling and monitoring the execution of program the basic functionality provided by debugger is the insertion of breakpoints within the code when the program is executed within the debuggerit stops at each breakpoint while the program is stoppedthe current value of variables can be inspected the standard python distribution includes module named pdbwhich provides debugging support directly within the interpreter most ides for pythonsuch as idleprovide debugging environments with graphical user interfaces