Skip to content

Instantly share code, notes, and snippets.

View lavantien's full-sized avatar
🧘‍♂️
chillax

лавантиен lavantien

🧘‍♂️
chillax
View GitHub Profile
@bmaupin
bmaupin / free-backend-hosting.md
Last active June 8, 2024 04:38
Free backend hosting
@posener
posener / go-table-driven-tests-parallel.md
Last active April 30, 2024 20:34
Be Careful with Table Driven Tests and t.Parallel()

Be Careful with Table Driven Tests and t.Parallel()

We Gophers, love table-driven-tests, it makes our unittesting structured, and makes it easy to add different test cases with ease.

Let’s create our table driven test, for convenience, I chose to use t.Log as the test function. Notice that we don't have any assertion in this test, it is not needed to for the demonstration.

func TestTLog(t *testing.T) {
	t.Parallel()
@vasanthk
vasanthk / System Design.md
Last active June 7, 2024 23:09
System Design Cheatsheet

System Design Cheatsheet

Picking the right architecture = Picking the right battles + Managing trade-offs

Basic Steps

  1. Clarify and agree on the scope of the system
  • User cases (description of sequences of events that, taken together, lead to a system doing something useful)
    • Who is going to use it?
    • How are they going to use it?