Skip to content

dotnetthailand/kata-workshop

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Kata Workshop

Build Status (GitHub Actions)

Langauge Status Langauge Status
.NET ? Go Lang GO CI
JavaScript js CI Python Python CI
TypeScript ts CI Rust Rust CI

Starter Templates

Repo Structure

  • templates - Kata Starter Template (Empty projects for different languages with a failing test), original by Softwerkskammer
  • workshop - Workshop Execerise order by complexity
  • exercises - Other problem and Exercises

Kata is way to learn TDD (Test-Driven Development)

TDD definition

Test Driven Development (TDD) is a process of creating software which uses automated tests not only as a tool for proving the code correctness but it leads to developing applications in a clean and well-designed way. by Krzysztof Zielonka

The TDD basic idea relies on working in a cycle (known as TDD-cycle) consisting of 3 stages:

  • Creating a test (RED – test fails)
  • Adding a code required to pass the test (GREEN – test passes)
  • Refactoring (BLUE)
graph LR;

Red-->Green;
Green-->Refactor;
Refactor-->Red;

Red:::ColorRed;
Green:::ColorGreen;
Refactor:::ColorBlue

classDef ColorGreen fill:#DBEDDB,stroke:#1C3829,color:#000;
classDef ColorRed fill:#FFE2DD,stroke:#5D1715,color:#000;
classDef ColorBlue fill:#d1e3ff,stroke:#1048a1,color:#000;
Loading

Uncle Bob’s “The Three Laws of TDD” article

  1. You are not allowed to write any production code unless it is to make a failing unit test pass
  2. You are not allowed to write any more of a unit test that is sufficient to fail, and compilation failures are failures
  3. You are not allowed to write any more production code that is sufficient to pass the one failing the unit test

แปลไทย ได้ว่า

  1. จะไม่เขียน production code ใดๆ จนกว่าจะทำให้ unit test ผ่านทั้งหมด
  2. จะไม่เขียน code ใดๆ ยกเว้นเขียน unit test ให้มัน fail
  3. จะไม่เขียน production code มากไปกว่าให้ unit test มันผ่าน

Resources

Kata Problems

TDD Concepts

Thai Resources

Ref

Original: https://github.com/swkBerlin/kata-bootstraps (For other Languages)