Skip to content

Commit

Permalink
Tests
Browse files Browse the repository at this point in the history
  • Loading branch information
Luc45 committed Apr 9, 2024
1 parent 4a4f483 commit 6a32163
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions src/src/Commands/TestTagsCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ protected function configure() {

protected function execute( InputInterface $input, OutputInterface $output ): int {
try {
$json = ( new RequestBuilder( get_manager_url() . "/wp-json/cd/v1/get_extensions" ) )
$json = ( new RequestBuilder( get_manager_url() . '/wp-json/cd/v1/get_extensions' ) )
->with_method( 'POST' )
->with_post_body( [
'list_tests' => true,
Expand All @@ -40,11 +40,10 @@ protected function execute( InputInterface $input, OutputInterface $output ): in
}

$table = new Table( $output );
$table->setHeaders(['Slug', 'E2E Tests', 'Type']);
$table->setHeaders( [ 'Slug', 'E2E Tests', 'Type' ] );

foreach ($test_tags as $tag => $data) {
$e2eTests = implode(', ', $data['tests']['e2e'] ?? []);
$table->addRow([$data['slug'], $e2eTests, $data['type']]);
foreach ( $test_tags as $tag => $data ) {
$table->addRow( [ $data['slug'], implode( ', ', $data['tests']['e2e'] ?? [] ), $data['type'] ] );
}

$table->render();
Expand Down

0 comments on commit 6a32163

Please sign in to comment.