Add PrintWriterTest and add ConsoleOutputStream to be able to write on the standard console when we run the unit test in a pc

Fix some strange behavior on appendDecf and add unit test