add selenium url to test results

This commit is contained in:
James 2019-09-23 16:13:11 +01:00
parent 495d4e0d26
commit e4c9d97697
2 changed files with 4 additions and 3 deletions

View File

@ -16,7 +16,7 @@ final class Poster{
$this->xml = simplexml_load_file($xml_path); $this->xml = simplexml_load_file($xml_path);
} }
public function post($url, $user, $pass, $repoUser, $repo){ public function post($url, $user, $pass, $repoUser, $repo, $title='Test Results'){
// open connection and repo // open connection and repo
$this->client=new Client($url, $user, $pass, true); $this->client=new Client($url, $user, $pass, true);
$this->repo=$this->client->getRepo($repoUser, $repo); $this->repo=$this->client->getRepo($repoUser, $repo);
@ -25,7 +25,7 @@ final class Poster{
// create the issue // create the issue
$issue=$this->repo->createIssue([ $issue=$this->repo->createIssue([
'title'=>'Test Results', 'title'=>$title,
'body'=>$this->report 'body'=>$this->report
]); ]);

View File

@ -16,7 +16,8 @@ $poster->post(
getenv('GiteaUser'), getenv('GiteaUser'),
getenv('GiteaPass'), getenv('GiteaPass'),
getenv('GiteaRepoUser'), getenv('GiteaRepoUser'),
getenv('GiteaRepo') getenv('GiteaRepo'),
'Test Results '.getenv('SeleniumBrowserUrl')
); );
} }