'', "password" => '', ]; $res = HttpBase::httpclient($data, $url, 'POST', null, 'form'); $this->assertEquals($expected, $res); } public function additiontJwt() { $scanner = new ClassMethodScanner(); // 指定目录路径 $directory = 'app/controller/api/'; // 获取类和方法 $classesAndMethods = $scanner->getClassesAndMethods($directory); $url_array = []; // 输出所有类和方法 foreach ($classesAndMethods as $url) { // 拼接描述并将状态码 401 加入 $url_array['测试不登录接口访问 ' . $url] = [$url, 401]; } return $url_array; } }