added Test.php, modified add function in test model, added writePermission,readPermission function to test model