Commit Graph

121 Commits

Author SHA1 Message Date
1153a0a5bd blogposts: use io.Reader interface to decouple 2024-09-24 21:06:57 +02:00
dec5f045a7 blogposts: refactor, create newPost func 2024-09-24 21:03:33 +02:00
6292463e90 blogposts: test get blog content 2024-09-24 20:57:28 +02:00
048e6cccac blogposts: add the first test 2024-09-23 23:09:10 +02:00
ef646bf98e clockface: refactor magic numbers 2024-09-23 22:40:35 +02:00
6837cd9fc1 clockface: add hours 2024-09-23 22:35:02 +02:00
c6ef156d88 clockface: refactor 2024-09-23 22:18:46 +02:00
a4531bde4c clockface: add minute hand tests 2024-09-23 22:16:06 +02:00
5a62fef4f3 clockface: add minute hand 2024-09-23 22:09:10 +02:00
b58e2436cd clockface: refactorize acceptance test 2024-09-23 18:01:35 +02:00
7b3fb0f91c clockface: xml 2024-09-23 17:24:40 +02:00
423c9e9567 clockface: add main func 2024-09-23 16:57:24 +02:00
c9c9b9bf7b clockface: part1 2024-09-23 16:49:29 +02:00
8629b537b0 roman: check number range 2024-09-22 22:00:50 +02:00
abc546178d roman: fix the number range 2024-09-22 21:51:40 +02:00
650ec27ec9 roman: add property based test with quick.check 2024-09-22 21:47:11 +02:00
52825e49b3 ***roman: add convert to arabic, the real one 2024-09-22 21:36:03 +02:00
715ea6477a roman: add convert to arabic 2024-09-22 21:28:24 +02:00
6da23dc641 roman: add more roman letters and test 2024-09-22 21:24:24 +02:00
7d751cab3d ***roman: refactor in the OOP way 2024-09-22 21:12:56 +02:00
b37f8a8d4c roman: add more tests 2024-09-22 21:09:51 +02:00
6f853c25d0 roman: add 9 and 10 2024-09-22 21:07:05 +02:00
0a75d86850 roman: add 5 and refactor 2024-09-22 21:02:27 +02:00
2515644d4f roman: refactor to use string building pattern 2024-09-22 20:59:11 +02:00
3a0808c599 roman: add 4 2024-09-22 20:57:12 +02:00
accb2c51dc roman: use stringBuild for better performance(?) 2024-09-22 20:54:22 +02:00
5f93a0b843 roman: get start with the roman numerals 2024-09-22 20:53:13 +02:00
7a32f26bd5 context: implement a spy response writer to check if anything is written 2024-09-21 20:46:07 +02:00
c5582275e7 context: realistic usage of context.
Use a go routine for the work logic. Here sleep and append to string.
Inside the go routine, select for ctx.Done(). If happens, just stop and
return.

In the outside function, select for ctx.Done() too. If it happens, that
means the work logic has not finished before canceled.
2024-09-21 20:35:43 +02:00
c0db9ab22b context: refactorize assert functions 2024-09-21 20:26:22 +02:00
0b181ccf0f context: setup timeout context 2024-09-21 20:20:15 +02:00
d49f952035 context: add basic context test 2024-09-21 20:07:09 +02:00
436bcad0e1 counter: Use a constructor 2024-09-21 19:48:58 +02:00
6ded953ec6 counter: fix mutex copy issue 2024-09-21 19:47:27 +02:00
572c8033f6 counter: handle racing situation with mutex 2024-09-21 19:43:09 +02:00
ea6f225992 counter: refactor, add assertCounter func 2024-09-21 18:21:56 +02:00
41ae820a21 counter: add baisics 2024-09-21 17:51:58 +02:00
Muyao CHEN
a0bad4d6e9 walk: handle functions... 2024-09-20 21:04:25 +02:00
Muyao CHEN
ab7818e9ea walk: handle channels 2024-09-20 21:00:47 +02:00
Muyao CHEN
574532f484 walk: handle map test separately 2024-09-20 20:51:44 +02:00
Muyao CHEN
10a93aeb27 walk: rerefacto 2024-09-20 20:44:40 +02:00
Muyao CHEN
61a0d0ff03 walk: deal with maps 2024-09-20 20:41:50 +02:00
Muyao CHEN
f64d75ca45 walk: deal with array 2024-09-20 20:37:54 +02:00
Muyao CHEN
799d730d14 walk: refacto slice and struct 2024-09-20 20:36:24 +02:00
Muyao CHEN
1c3ad9b9d8 walk: refacto 2024-09-20 20:32:37 +02:00
Muyao CHEN
049c346e63 walk: deal with slices 2024-09-20 20:27:53 +02:00
Muyao CHEN
80959f822b waik: work with pointer 2024-09-20 20:19:49 +02:00
Muyao CHEN
30a408c9e4 walk: recursively search for string 2024-09-20 20:15:59 +02:00
Muyao CHEN
8026475424 walk: check if the field is of string type 2024-09-20 20:05:32 +02:00
Muyao CHEN
122770ae5c walk: loop on the string fields 2024-09-20 20:00:05 +02:00