File tree Expand file tree Collapse file tree 1 file changed +24
-0
lines changed
src/test/php/Gomoob/Pushwoosh/Model/Request Expand file tree Collapse file tree 1 file changed +24
-0
lines changed Original file line number Diff line number Diff line change @@ -73,6 +73,30 @@ public function testGetSetApplication()
7373 $ this ->assertSame ('APPLICATION ' , $ setTagsRequest ->getApplication ());
7474 }
7575
76+ /**
77+ * Test method for the `getAuth()` and `setAuth($auth)` functions.
78+ */
79+ public function testGetSetAuth ()
80+ {
81+ $ setTagsRequest = new SetTagsRequest ();
82+
83+ // Gets for `getAuth()`
84+ try {
85+ $ setTagsRequest ->getAuth ();
86+ $ this ->fail ('Must have throw a PushwooshException ! ' );
87+ } catch (PushwooshException $ pex ) {
88+ $ this ->assertSame ('This request does not support the \'auth \' parameter ! ' , $ pex ->getMessage ());
89+ }
90+
91+ // Gets for `getAuth()`
92+ try {
93+ $ setTagsRequest ->setAuth ('XXXX ' );
94+ $ this ->fail ('Must have throw a PushwooshException ! ' );
95+ } catch (PushwooshException $ pex ) {
96+ $ this ->assertSame ('This request does not support the \'auth \' parameter ! ' , $ pex ->getMessage ());
97+ }
98+ }
99+
76100 /**
77101 * Test method for the <tt>getHwid()</tt> and <tt>setHwid($hwid)</tt> functions.
78102 */
You can’t perform that action at this time.
0 commit comments