DAY 19일차
1. What is better, to throw Exceptions or return error codes? /Exceptions
2.When should we write try/catch/finally? * / First, before we write any code.
3.What kind of information should our error messages have? * /The operation that failed, type of failure, more information about the error.
4.Why shouldn’t we return ‘null’ from methods/functions? */We might forget to check for null and can easily have null pointer exceptions.
5.s passing ‘null’ as an argument a good practice? * / No
6.Having dirty tests can be worse than having no tests at all. * / True
7.Test code is as important as production code. * / True
8.How many concepts should a test function test? * / One
9.Should tests depend on each other * / No
10.What output should a test have? * / Boolean
7~9장에 대한 중간점검 퀴즈를 풀어보았다. TDD개발방법에 대해서 더 생각해보고 예외처리, unit test code 작성에 대해서 더 생각해볼수있는 챕터였다.
'개발 외의 것들 > 책을읽읍시다.' 카테고리의 다른 글
[TIR]SQL 첫걸음 1~4강 (0) | 2022.02.11 |
---|---|
[TIR]cleancode 10.클래스 (0) | 2022.02.10 |
[TIR]cleancode 9. 단위 테스트 (0) | 2022.02.06 |
[TIR]cleancode 4.5.6 중간점검 (0) | 2022.02.03 |
[TIR]cleancode 7.오류 처리 (0) | 2022.02.02 |