How To Troubleshoot Collaboration Apps for the Modern Connected Worker
Clean code
1.
2.
3.
4.
5.
6.
7.
8.
9.
10.
11.
12.
13.
14.
15.
16.
17.
18.
19.
20.
21.
22.
23.
24.
25.
26.
27.
28. Use the F.I.R.S.T rule for testing:
● The test is FAST running
● The test should be
INDEPENDENT of other
● REPEATABLE in various
environments
● SELF- VALIDATING
● TIMELY
29. Rules given by Kent Beck to create good designs:
● Run all tests: they verify that the system behaves as expected.
● Eliminate duplication: for with duplicate code has additional work.
● To express the intention of the programmer: use more expressive code can
to Facilitate maintenance. Choose good names for functions, classes and
tests shouldn’t be small and well written.
● Minimize the number of classes and methods: following this pattern can
ignore it if the classes are very small.
● Apply all knowledge to improve the design during refactoring: greater
cohesion, reducing coupling, separate responsibilities, reducing classes and
methods, choose the best names.
30.
31.
32.
33. Padrões para Nossos Projetos
● Domínio é em Português
○ ex: Pessoa,Conta,Cliente ao invés de People,Account
● Métodos devem ser em inglês
○ ex: buildPessoa, getContaByCpf, findClienteByNome
● Serviço deve conter camadas como:
○ API,Service,Repository,Client,
○ Input,Output,Model,
○ DTO(para JDBC Template)
○ Entity (para Spring Data)
●