🌍 Back-end Web Developement · subject
Back-end Web Developement Testing Syllabus
Every chapter and topic of Testing examined in Back-end Web Developement — 3 chapters, 7 topics, plus 50 flashcards written against it.
Testing syllabus — full chapter and topic list
Expand any chapter to see its topics and sub-topics. This is the whole examinable outline for Testing in Back-end Web Developement, not a summary of it.
-
Unit Testing
3 topics- JUnit
- Mocha
- PyTest
-
Integration Testing
2 topics- Postman
- Selenium
-
End-to-End Testing
2 topics- Cypress
- TestCafe
Testing flashcards for Back-end Web Developement
23 of 50 cards from the Testing deck — real questions with worked answers.
What is unit testing?
A software testing method where individual units or components of code (typically single functions, methods, or classes) are tested in isolation to verify they behave as expected.
What is the difference between unit testing and integration testing?
Unit testing verifies individual components in isolation (often with mocks/stubs), while integration testing verifies that multiple components work correctly together, including their interactions and data flow.
What does the acronym in the AAA testing pattern stand for?
Arrange, Act, Assert - a three-step structure for a test: set up data/preconditions (Arrange), execute the code under test (Act), and verify the outcome (Assert).
In test suites, how is code coverage percentage calculated?
$$\text{Coverage} = \frac{\text{lines (or branches) executed by tests}}{\text{total lines (or branches)}} \times 100\%$$
What is a test double, and name its main types?
A test double is any object that stands in for a real dependency during testing. Main types: dummy, stub, spy, mock, and fake.
What programming language and framework family is JUnit built for?
JUnit is a unit testing framework for the Java programming language, and is the reference member of the xUnit family.
In JUnit 5, which annotation marks a method as a test?
@Test - it marks a method to be run by the test runner as a test case.
In JUnit 5, what are the annotations @BeforeEach and @AfterEach used for?
@BeforeEach runs before every test method (setup), and @AfterEach runs after every test method (teardown), so each test starts from a fresh, known state.
In JUnit 5, what is the difference between @BeforeAll and @BeforeEach?
@BeforeAll runs once before all tests in the class (and must be static by default), while @BeforeEach runs before each individual test method.
What are the three main modules that make up JUnit 5?
JUnit Platform (launches test frameworks on the JVM), JUnit Jupiter (new programming and extension model/API), and JUnit Vintage (runs legacy JUnit 3 and 4 tests).
In JUnit 5, which annotation is used to write a parameterized test, and how are inputs supplied?
@ParameterizedTest marks the method; inputs are supplied via source annotations such as @ValueSource, @CsvSource, @MethodSource, or @EnumSource.
In JUnit 5, how do you assert that a specific exception is thrown?
Use assertThrows(ExpectedException.class, () -> code()), which fails the test if the executable does not throw the expected exception type and returns the thrown exception for further assertions.
In JUnit 5, what does the @Disabled annotation do?
It disables a test class or test method so it is skipped by the test runner (typically shown as skipped, not passed or failed).
Which library is commonly paired with JUnit to create mock objects in Java?
Mockito - it is used to create mocks, stubs, and spies for dependencies so units can be tested in isolation.
What is Mocha, and what environment does it primarily run in?
Mocha is a feature-rich JavaScript test framework that runs on Node.js and in the browser, providing the test structure (describe/it) but not assertions by default.
In Mocha, what is the purpose of the describe() and it() functions?
describe() groups related tests into a suite (and can be nested), while it() defines an individual test case containing the assertions.
Why is Mocha often paired with a separate assertion library such as Chai?
Because Mocha does not ship with its own assertion library; Chai (or Node's assert) provides the assertion styles (expect, should, assert) needed to verify results.
In Mocha, what are the four main hooks for setup and teardown?
before() (once before all tests in a block), after() (once after all), beforeEach() (before each test), and afterEach() (after each test).
How do you test asynchronous code in Mocha?
Either accept a done callback and call done() when finished, or return a Promise / use an async function so Mocha waits for it to resolve.
In Mocha, how do you run only or skip a specific test?
Use .only (e.g. it.only or describe.only) to run just that test/suite, and .skip (e.g. it.skip) to skip it.
What is PyTest?
PyTest is a mature, full-featured testing framework for Python that supports simple assert-based tests, fixtures, parameterization, and a rich plugin ecosystem.
How does PyTest discover test files and functions by default?
By default it collects files matching test_*.py or *_test.py, and within them functions prefixed with test_ (and methods in classes prefixed with Test).
Why does PyTest not require special assertion methods like assertEqual?
PyTest rewrites the plain Python assert statement to provide detailed introspection on failure, so you can just write assert x == y instead of using methods like self.assertEqual.
Planning Testing for Back-end Web Developement
Testing is about 10% of the Back-end Web Developement syllabus by topic count — 7 of 67 topics, spread over 3 chapters. At roughly 45 minutes per topic plus 12 minutes per sub-topic, a first pass runs to about 5 hours.
The heaviest chapters are Unit Testing (3 topics), Integration Testing (2 topics), End-to-End Testing (2 topics) . Front-load those while your energy is high; the short chapters are better revision filler later.
Work top-down: read the chapter, then tick topics off individually rather than marking the whole chapter done. Sub-topics are where silent gaps hide.
Testing (Back-end Web Developement) FAQ
What is in the Back-end Web Developement Testing syllabus?
Testing is split into 3 chapters — Unit Testing, Integration Testing and End-to-End Testing, containing 7 topics and 0 sub-topics in total.
How is Testing structured in the Back-end Web Developement syllabus?
3 chapters. Testing accounts for about 10% of the topics in the whole Back-end Web Developement syllabus (7 of 67).
How long should I spend on Testing for Back-end Web Developement?
Budget around 5 hours for a first pass through Testing — about 45 minutes per topic plus 12 minutes per sub-topic across its 7 topics. Add revision cycles on top.
Are there flashcards for Back-end Web Developement Testing?
Yes — a 50-card Testing deck. Sample cards are printed on this page, and the full deck is free in the Examius app with spaced repetition scheduling.