Assignment 1(Stqa)
Assignment 1(Stqa)
import csv
writer = csv.writer(file)
# Example Defects
log_defect('D001', 'Login button not working', 'Critical', 'High', 'Open', 'Dev Team', 'Windows 10, Chrome', '01-
03-2024')
log_defect('D002', 'Slow page load in reports', 'Medium', 'Normal', 'In Progress', 'Dev Team', 'MacOS, Safari',
'02-03-2024')
log_defect('D003', 'Incorrect error message', 'Low', 'Low', 'Resolved', 'Tester', 'Windows 11, Edge', '03-03-
2024')
DEFECT REPOSITORY:
VALIDATION TESTING:
Validation testing ensures that the final product meets user requirements and functions as intended. It involves
evaluating the software against the business requirements and user expectations rather than just checking
technical specifications. The goal is to verify that the software system achieves its intended purpose.
INTEGRATION TESTING:
Integration testing examines how different modules of the software interact with each other. It ensures that data
flow and communication between modules work correctly. This testing phase helps uncover defects in
interactions between integrated units.
• Top-Down Integration: Testing starts with high-level modules and gradually integrates lower-level
ones.
• Bottom-Up Integration: Lower-level modules are tested first before integrating with higher-level
modules.
• Big Bang Integration: All modules are integrated and tested simultaneously.
• Incremental Integration: Modules are integrated and tested in phases to detect issues early.
• System Testing: Evaluates the complete, integrated system against functional and non-functional
requirements.
• Acceptance Testing: Conducted to determine if the system is ready for deployment. It includes:
o Alpha Testing: Performed by internal users before release.
o Beta Testing: Conducted by external users in a real-world environment before final release.
GUI TESTING:
GUI (Graphical User Interface) testing ensures that the visual elements of an application function correctly. It
involves testing the responsiveness, consistency, and user-friendliness of the interface, including:
VERIFICATION TESTING:
Verification testing checks if the software meets technical specifications and is built according to design
requirements. It answers the question: "Are we building the product correctly?"
REGRESSION TESTING:
Regression testing ensures that new updates or fixes do not break existing functionality. It involves re-running
previously executed test cases to verify that recent code changes have not introduced new defects.
1. calculator.py
return a + b
return a - b
return a * b
if b == 0:
return a / b
2. test_calculator.py
import unittest
class TestCalculator(unittest.TestCase):
def test_add(self):
self.assertEqual(calculator.add(5, 3), 8)
self.assertEqual(calculator.add(-1, 1), 0)
def test_subtract(self):
self.assertEqual(calculator.subtract(10, 5), 5)
def test_multiply(self):
self.assertEqual(calculator.multiply(3, 3), 9)
def test_divide(self):
self.assertEqual(calculator.divide(10, 2), 5)
if __name__ == '__main__':
unittest.main()
OUTCOME: