Skip to content

Instantly share code, notes, and snippets.

@Cjkjvfnby
Cjkjvfnby / README.md
Last active April 23, 2021 20:02
Async playground

Playground for async code

Playground with async code visualization. Each line is separate coroutine.

Legend

Each char in outpput represents 0.1 second

  • > job before wait
  • - wait
  • < job after wait
  • . routine does not work
@Cjkjvfnby
Cjkjvfnby / out
Created April 3, 2021 08:26
Testing different implementations with pytest. To add/remove implementation for testing you need just change one line of code.
test_impls.py::test_integer_rounded_to_itself[do_round] PASSED [ 16%]
test_impls.py::test_integer_rounded_to_itself[cut] PASSED [ 33%]
test_impls.py::test_quarter_rounded_down[do_round] PASSED [ 50%]
test_impls.py::test_quarter_rounded_down[cut] PASSED [ 66%]
test_impls.py::test_three_fore_rounded_up[do_round] PASSED