Bird
Raised Fist0
Testing Fundamentalstesting~15 mins

Quality assurance vs quality control in Testing Fundamentals - Automation Approaches Compared

Choose your learning style10 modes available
Verify Quality Assurance and Quality Control definitions on About page
Preconditions (1)
Step 1: Locate the section titled 'Quality Assurance'
Step 2: Verify the text under 'Quality Assurance' matches 'Quality assurance (QA) is the process of ensuring that the product meets the required standards through planned and systematic activities.'
Step 3: Locate the section titled 'Quality Control'
Step 4: Verify the text under 'Quality Control' matches 'Quality control (QC) is the process of identifying defects in the actual products produced.'
✅ Expected Result: The About page correctly displays the definitions for Quality Assurance and Quality Control as specified.
Automation Requirements - Selenium with Python
Assertions Needed:
Assert the QA section text matches the expected definition
Assert the QC section text matches the expected definition
Best Practices:
Use explicit waits to ensure elements are loaded before accessing
Use clear and maintainable locators (e.g., By.ID or By.CSS_SELECTOR)
Separate test logic and assertions clearly
Automated Solution
Testing Fundamentals
from selenium import webdriver
from selenium.webdriver.common.by import By
from selenium.webdriver.support.ui import WebDriverWait
from selenium.webdriver.support import expected_conditions as EC
import unittest

class TestQualityDefinitions(unittest.TestCase):
    def setUp(self):
        self.driver = webdriver.Chrome()
        self.driver.get('https://example.com/about')
        self.wait = WebDriverWait(self.driver, 10)

    def test_quality_definitions(self):
        driver = self.driver
        wait = self.wait

        # Wait for QA section and verify text
        qa_section = wait.until(EC.visibility_of_element_located((By.ID, 'quality-assurance')))
        expected_qa_text = 'Quality assurance (QA) is the process of ensuring that the product meets the required standards through planned and systematic activities.'
        actual_qa_text = qa_section.text.strip()
        self.assertEqual(actual_qa_text, expected_qa_text, 'QA definition text does not match')

        # Wait for QC section and verify text
        qc_section = wait.until(EC.visibility_of_element_located((By.ID, 'quality-control')))
        expected_qc_text = 'Quality control (QC) is the process of identifying defects in the actual products produced.'
        actual_qc_text = qc_section.text.strip()
        self.assertEqual(actual_qc_text, expected_qc_text, 'QC definition text does not match')

    def tearDown(self):
        self.driver.quit()

if __name__ == '__main__':
    unittest.main()

This test script uses Selenium with Python's unittest framework to automate verification of the Quality Assurance and Quality Control definitions on the About page.

In setUp, the browser opens the About page URL. We use WebDriverWait with explicit waits to ensure the sections are visible before accessing their text.

We locate the QA and QC sections by their id attributes, which is a best practice for stable and clear locators.

Assertions compare the actual text on the page with the expected definitions exactly, ensuring correctness.

Finally, tearDown closes the browser after the test.

Common Mistakes - 3 Pitfalls
Using time.sleep() instead of explicit waits
Using brittle XPath locators that depend on page layout
Not verifying the exact text content
Bonus Challenge

Now add data-driven testing with 3 different pages that have QA and QC definitions

Show Hint

Practice

(1/5)
1. Which statement best describes the main focus of Quality Assurance (QA) in software testing?
easy
A. QA focuses on improving the process to prevent defects before they occur.
B. QA focuses on finding defects in the finished product.
C. QA is only about testing the software after development.
D. QA is responsible for fixing bugs found in the software.

Solution

  1. Step 1: Understand QA's role

    Quality Assurance is about the process and preventing defects early.
  2. Step 2: Compare with other options

    Options A, B, and D describe Quality Control or development tasks, not QA.
  3. Final Answer:

    QA focuses on improving the process to prevent defects before they occur. -> Option A
  4. Quick Check:

    QA = Process improvement [OK]
Hint: QA is about process, not product defects [OK]
Common Mistakes:
  • Confusing QA with QC
  • Thinking QA only tests software
  • Believing QA fixes bugs
2. Which of the following is the correct description of Quality Control (QC)?
easy
A. QC is about designing processes to avoid defects.
B. QC involves testing the product to find defects.
C. QC is responsible for writing code.
D. QC manages project timelines.

Solution

  1. Step 1: Define QC

    Quality Control focuses on inspecting and testing the product to detect defects.
  2. Step 2: Eliminate incorrect options

    Options A, C, and D describe other roles unrelated to QC.
  3. Final Answer:

    QC involves testing the product to find defects. -> Option B
  4. Quick Check:

    QC = Product testing [OK]
Hint: QC finds defects in the product [OK]
Common Mistakes:
  • Mixing QC with process design
  • Assuming QC writes code
  • Confusing QC with project management
3. Consider this scenario: A team creates a checklist to improve their coding process and also runs tests to find bugs in the software. Which activities represent QA and which represent QC?
medium
A. Both creating checklist and running tests are QC.
B. Creating checklist is QC; running tests is QA.
C. Creating checklist is QA; running tests is QC.
D. Both creating checklist and running tests are QA.

Solution

  1. Step 1: Identify QA activity

    Creating a checklist to improve process is a QA activity.
  2. Step 2: Identify QC activity

    Running tests to find bugs is a QC activity.
  3. Final Answer:

    Creating checklist is QA; running tests is QC. -> Option C
  4. Quick Check:

    Checklist = QA, Tests = QC [OK]
Hint: Process improvement = QA; Testing product = QC [OK]
Common Mistakes:
  • Swapping QA and QC roles
  • Thinking both are same
  • Ignoring process vs product difference
4. A tester wrote this statement: "Quality Assurance is responsible for finding bugs in the software." What is wrong with this statement?
medium
A. QA manages the software deployment process.
B. QA only fixes bugs, not finds them.
C. QA is the same as QC, so the statement is correct.
D. QA is responsible for preventing defects, not finding them.

Solution

  1. Step 1: Understand QA's responsibility

    QA focuses on preventing defects by improving processes.
  2. Step 2: Identify error in statement

    Finding bugs is the role of QC, not QA.
  3. Final Answer:

    QA is responsible for preventing defects, not finding them. -> Option D
  4. Quick Check:

    QA prevents defects, QC finds them [OK]
Hint: QA prevents; QC detects defects [OK]
Common Mistakes:
  • Confusing QA with QC
  • Assuming QA finds bugs
  • Mixing roles of QA and developers
5. A software company wants to improve product quality. They plan to implement process audits and also increase automated testing. Which of these actions correspond to QA and which to QC?
hard
A. Process audits are QA; automated testing is QC.
B. Both process audits and automated testing are QC.
C. Process audits are QC; automated testing is QA.
D. Both process audits and automated testing are QA.

Solution

  1. Step 1: Analyze process audits

    Process audits check and improve processes, so they are QA activities.
  2. Step 2: Analyze automated testing

    Automated testing finds defects in the product, so it is QC.
  3. Final Answer:

    Process audits are QA; automated testing is QC. -> Option A
  4. Quick Check:

    Audits = QA, Automated tests = QC [OK]
Hint: Audits improve process (QA); tests find bugs (QC) [OK]
Common Mistakes:
  • Mixing audits with testing
  • Assuming all testing is QA
  • Ignoring process vs product focus
Recommended

Ready to prove it?

Pass the test and this pattern moves unknown strong while earning +1 Grip toward your certificate.

10 questions~5 mineasy hard