Skip to content

Instantly share code, notes, and snippets.

View kylebebak's full-sized avatar

Kyle Bebak kylebebak

View GitHub Profile
@jfcherng
jfcherng / st4-changelog.md
Last active April 20, 2024 00:25
Sublime Text 4 changelog just because it's not on the official website yet.
@androidfred
androidfred / anti_tests.md
Last active March 3, 2021 02:08
Anti-tests

Test your tests

Summary: test interfaces, not implementations

Tests that pass when something is actually broken, and fail when things actually do work, are worse than useless- they are positively harmful.

The requirement

Let's say we've been tasked with returning 400 when GET /users/<userId> is called with a negative userId.

The test

The requirement can be turned into a test that hits the endpoint with a negative userId and checks that a 400 is returned: