profiling: add tests

Some functions are missing:

- profile_self
- profile_get_wait
- profile_set_wait
- profile_sub_wait