changed test function injection