board/cpu/test: some cosmetic fixes to the code

Hi, this PR looks worse then it is, I basically removed a lot or newlines and made the code a little more compact. Also I introduced one more define `SPI_x_XXX_AF` for the pin configuration, to make this more flexible...