[tests] add some unit tests