Add functions for tests