@@ -27,8 +27,8 @@ public function testGet(): void
2727 $ body = (object ) Json::decode ($ response ->getBody ());
2828
2929 $ this ->assertIsObject ($ body );
30- $ this ->assertObjectHasAttribute ('args ' , $ body );
31- $ this ->assertObjectHasAttribute ('test ' , $ body ->args );
30+ $ this ->assertObjectHasProperty ('args ' , $ body );
31+ $ this ->assertObjectHasProperty ('test ' , $ body ->args );
3232 $ this ->assertEquals ('HelloWorld ' , $ body ->args ->test [0 ]);
3333 }
3434
@@ -45,8 +45,8 @@ public function testPost(): void
4545 $ body = (object ) Json::decode ($ response ->getBody ());
4646
4747 $ this ->assertIsObject ($ body );
48- $ this ->assertObjectHasAttribute ('json ' , $ body );
49- $ this ->assertObjectHasAttribute ('test ' , $ body ->json );
48+ $ this ->assertObjectHasProperty ('json ' , $ body );
49+ $ this ->assertObjectHasProperty ('test ' , $ body ->json );
5050 $ this ->assertEquals ('HelloWorld ' , $ body ->json ->test );
5151 }
5252
@@ -61,7 +61,7 @@ public function testPostYaml(): void
6161 $ body = (object ) Json::decode ($ response ->getBody ());
6262
6363 $ this ->assertIsObject ($ body );
64- $ this ->assertObjectHasAttribute ('data ' , $ body );
64+ $ this ->assertObjectHasProperty ('data ' , $ body );
6565 $ this ->assertEquals ($ this ->getYamlBase64 (), $ body ->data );
6666 }
6767
@@ -78,8 +78,8 @@ public function testPostFile(): void
7878 $ body = (object ) Json::decode ($ response ->getBody ());
7979
8080 $ this ->assertIsObject ($ body );
81- $ this ->assertObjectHasAttribute ('files ' , $ body );
82- $ this ->assertObjectHasAttribute ('file ' , $ body ->files );
81+ $ this ->assertObjectHasProperty ('files ' , $ body );
82+ $ this ->assertObjectHasProperty ('file ' , $ body ->files );
8383 $ this ->assertEquals (file_get_contents ($ this ->getTextFilePath ()), $ body ->files ->file [0 ]);
8484 }
8585
@@ -96,8 +96,8 @@ public function testPut(): void
9696 $ body = (object ) Json::decode ($ response ->getBody ());
9797
9898 $ this ->assertIsObject ($ body );
99- $ this ->assertObjectHasAttribute ('json ' , $ body );
100- $ this ->assertObjectHasAttribute ('test ' , $ body ->json );
99+ $ this ->assertObjectHasProperty ('json ' , $ body );
100+ $ this ->assertObjectHasProperty ('test ' , $ body ->json );
101101 $ this ->assertEquals ('HelloWorld ' , $ body ->json ->test );
102102 }
103103
@@ -131,8 +131,8 @@ public function testBasicAuth(): void
131131 $ body = (object ) Json::decode ($ response ->getBody ());
132132
133133 $ this ->assertIsObject ($ body );
134- $ this ->assertObjectHasAttribute ('authorized ' , $ body );
135- $ this ->assertObjectHasAttribute ('user ' , $ body );
134+ $ this ->assertObjectHasProperty ('authorized ' , $ body );
135+ $ this ->assertObjectHasProperty ('user ' , $ body );
136136
137137 $ this ->assertEquals (true , $ body ->authorized );
138138 $ this ->assertEquals ($ username , $ body ->user );
@@ -153,8 +153,8 @@ public function testTokenAuth(): void
153153 $ body = (object ) Json::decode ($ response ->getBody ());
154154
155155 $ this ->assertIsObject ($ body );
156- $ this ->assertObjectHasAttribute ('headers ' , $ body );
157- $ this ->assertObjectHasAttribute ('X-Gotify-Key ' , $ body ->headers );
156+ $ this ->assertObjectHasProperty ('headers ' , $ body );
157+ $ this ->assertObjectHasProperty ('X-Gotify-Key ' , $ body ->headers );
158158
159159 $ headers = get_object_vars ($ body ->headers );
160160
0 commit comments