Question: All lines in my AppStats look like this: `real=19ms cpu=0ms api=0ms overhead=0ms`, it has the correct real time, but the other values are always 0. Anyone have this problem before or know how to fix this?

Answer: 
It's just a convention that a 0 exit code means success. [EXIT\_SUCCESS](http://www.cplusplus.com/reference/clibrary/cstdlib/EXIT_SUCCESS/) will be 0 on almost every modern system.

EDIT:

"why both test 0 and test 1 returns 0(success) ?"

That's a completely different question. The answer is that passing a single argument to test always results in success unless that argument is the null string (""). See the [Open Group documentation](https://www.opengroup.org/onlinepubs/009695399/utilities/test.html).
it's a convention dated back to the early days of Unix.

By convention, all system calls return 0 if succeed, non-zero otherwise, because then different numbers can be used to indicate different reason of failure.

Shells follow this convention, 0 means last command succeeded, non-zero otherwise. Similarly, the non-zero return value comes in handy for output error messages: e.g. 1: "brain dead", 2: "heartless", and so on.