File tree Expand file tree Collapse file tree 3 files changed +45
-12
lines changed
application/modules/test/controllers
tests/unit/modules/test/controllers Expand file tree Collapse file tree 3 files changed +45
-12
lines changed Original file line number Diff line number Diff line change 2828 */
2929 $ crud = new Crud (Test \Crud::getInstance ());
3030
31- $ crud ->get ('system ' , 'crud/get ' , 'Read ' );
32- $ crud ->post ('system ' , 'crud/post ' , 'Create ' );
33- $ crud ->put ('system ' , 'crud/put ' , 'Update ' );
34- $ crud ->delete ('system ' , 'crud/delete ' , 'Delete ' );
31+ $ crud
32+ ->get ('system ' , 'crud/get ' )
33+ ->acl ('Read ' )
34+ ;
35+ $ crud
36+ ->post ('system ' , 'crud/post ' )
37+ ->acl ('Create ' )
38+ ;
39+ $ crud
40+ ->put ('system ' , 'crud/put ' )
41+ ->acl ('Update ' )
42+ ;
43+ $ crud
44+ ->delete ('system ' , 'crud/delete ' )
45+ ->acl ('Delete ' )
46+ ;
3547
3648 return $ crud ->run ();
3749};
Original file line number Diff line number Diff line change 3131 */
3232 $ rest = new Rest (Test \Crud::getInstance ());
3333
34- $ rest ->head ('system ' , 'rest/head ' , 'Read ' );
35- $ rest ->get ('system ' , 'rest/get ' , 'Read ' );
36- $ rest ->options ('system ' , 'rest/options ' , 'Read ' );
37- $ rest ->post ('system ' , 'rest/post ' , 'Create ' );
38- $ rest ->put ('system ' , 'rest/put ' , 'Update ' );
39- $ rest ->patch ('system ' , 'rest/put ' , 'Update ' );
40- $ rest ->delete ('system ' , 'rest/delete ' , 'Delete ' );
34+ $ rest
35+ ->head ('system ' , 'rest/head ' )
36+ ->acl ('Read ' )
37+ ;
38+ $ rest
39+ ->get ('system ' , 'rest/get ' )
40+ ->acl ('Read ' )
41+ ;
42+ $ rest
43+ ->options ('system ' , 'rest/options ' )
44+ ->acl ('Read ' )
45+ ;
46+ $ rest
47+ ->post ('system ' , 'rest/post ' )
48+ ->acl ('Create ' )
49+ ;
50+ $ rest
51+ ->put ('system ' , 'rest/put ' )
52+ ->acl ('Update ' )
53+ ;
54+ $ rest
55+ ->patch ('system ' , 'rest/put ' )
56+ ->acl ('Update ' )
57+ ;
58+ $ rest
59+ ->delete ('system ' , 'rest/delete ' )
60+ ->acl ('Delete ' )
61+ ;
4162
4263 return $ rest ->run ();
4364};
Original file line number Diff line number Diff line change @@ -172,7 +172,7 @@ public function testUpdate()
172172 ['name ' => 'Leonardo ' , 'email ' => 'leonardo@turtles.ua ' ],
173173 RequestMethod::PUT
174174 );
175- ;
175+
176176 self ::assertOk ();
177177
178178 $ id = Db::fetchOne (
You can’t perform that action at this time.
0 commit comments