mirror of
https://github.com/solidtime-io/solidtime.git
synced 2026-06-15 05:22:44 +01:00
Compare commits
2 Commits
7035d5fd6e
...
feature/pa
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
7ae4f2171d | ||
|
|
96acd4b962 |
2
.github/workflows/phpunit.yml
vendored
2
.github/workflows/phpunit.yml
vendored
@@ -60,7 +60,7 @@ jobs:
|
||||
php artisan passport:keys
|
||||
|
||||
- name: "Run PHPUnit"
|
||||
run: php artisan test --stop-on-failure --coverage-text --coverage-clover=coverage.xml
|
||||
run: php artisan test --parallel --stop-on-failure --coverage-text --coverage-clover=coverage.xml
|
||||
|
||||
- name: "Upload coverage reports to Codecov"
|
||||
uses: codecov/codecov-action@v5.4.2
|
||||
|
||||
@@ -12,12 +12,12 @@ use Illuminate\Support\Facades\Artisan;
|
||||
use Illuminate\Support\Facades\Http;
|
||||
use PHPUnit\Framework\Attributes\CoversClass;
|
||||
use PHPUnit\Framework\Attributes\UsesClass;
|
||||
use Tests\TestCase;
|
||||
use Tests\TestCaseWithDatabase;
|
||||
|
||||
#[CoversClass(SelfHostTelemetryCommand::class)]
|
||||
#[CoversClass(ApiService::class)]
|
||||
#[UsesClass(SelfHostTelemetryCommand::class)]
|
||||
class SelfHostTelemetryCommandTest extends TestCase
|
||||
class SelfHostTelemetryCommandTest extends TestCaseWithDatabase
|
||||
{
|
||||
public function test_telemetry_sends_data_to_telemetry_endpoint_of_solidtime_cloud(): void
|
||||
{
|
||||
@@ -30,9 +30,12 @@ class SelfHostTelemetryCommandTest extends TestCase
|
||||
$exitCode = $this->withoutMockingConsoleOutput()->artisan('self-host:telemetry');
|
||||
|
||||
// Assert
|
||||
$this->assertSame(Command::SUCCESS, $exitCode);
|
||||
$output = Artisan::output();
|
||||
$this->assertSame('', $output);
|
||||
if ($exitCode !== Command::SUCCESS) {
|
||||
dump($output);
|
||||
}
|
||||
$this->assertSame(Command::SUCCESS, $exitCode);
|
||||
}
|
||||
|
||||
public function test_telemetry_sends_fails_gracefully_if_response_has_error_status_code(): void
|
||||
|
||||
Reference in New Issue
Block a user