testing/provisioner: fixed a race problem in fake provisioner.
removed method used only by tests to a test file.