test code for plug