@@ -59,3 +59,11 @@ test('standalone binding rejects other drivers without querying them', function
|
||||
$db->shouldReceive('getDriverName')->once()->andReturn('sqlite');
|
||||
expect(fn () => StandaloneRuntime::databaseBinding($db))->toThrow(LogicException::class, 'COMPRAS_RUNTIME_DATABASE_DRIVER');
|
||||
});
|
||||
|
||||
test('standalone data classification remains explicit and defaults to synthetic', function () {
|
||||
expect((new StandaloneRuntime([], new StandaloneArtifact))->syntheticOnly())->toBeTrue()
|
||||
->and((new StandaloneRuntime(['enabled' => true], new StandaloneArtifact))->syntheticOnly())->toBeTrue()
|
||||
->and((new StandaloneRuntime(['enabled' => true, 'synthetic_only' => false], new StandaloneArtifact))->syntheticOnly())->toBeFalse();
|
||||
expect(fn () => (new StandaloneRuntime(['enabled' => true, 'synthetic_only' => 'false'], new StandaloneArtifact))->syntheticOnly())
|
||||
->toThrow(LogicException::class, 'COMPRAS_RUNTIME_DATA_CLASSIFICATION');
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user