#!/usr/bin/env php > 1 通过sonarqubeID,获取SonarQube项目数量 >> 1 通过sonarqubeID,关键字,搜索获取SonarQube项目 >> 1 当sonarqubeID为0时,获取SonarQube项目列表 >> return empty */ $sonarqubeID = 2; $keyword = '02'; $sonarqube = new sonarqubeTest(); r($sonarqube->apiGetProjectsTest($sonarqubeID)) && p() && e('1'); //通过sonarqubeID,获取SonarQube项目列表 r(count($sonarqube->apiGetProjectsTest($sonarqubeID)) > 0) && p() && e('1'); //通过sonarqubeID,获取SonarQube项目数量 r($sonarqube->apiGetProjectsTest($sonarqubeID, $keyword)) && p() && e('1'); //通过sonarqubeID,关键字,搜索获取SonarQube项目 r($sonarqube->apiGetProjectsTest(0)) && p() && e('return empty'); //当sonarqubeID为0时,获取SonarQube项目列表