added test for daemon mode

* added a test with counting of none daemon threads before, while and after using the driver