tested creating and removing semaphore