add testing main code