Skip to content

Commit

Permalink
Fix method name
Browse files Browse the repository at this point in the history
  • Loading branch information
AdamVyborny committed May 6, 2024
1 parent c53d04a commit efee749
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ public function setColumns(array $columns): ManifestOptions
return $this;
}

public function setSchema(ManifestOptionsSchema $schema): ManifestOptions
public function addSchema(ManifestOptionsSchema $schema): ManifestOptions
{
if ($this->columns) {
throw new OptionsValidationException('Cannot set schema when columns are set');
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ public function provideOptions(): array
'value' => 'A different value',
],
],
'column_metadata' => (object)[
'column_metadata' => (object) [
'123456' => [
[
'key' => 'int.column.name',
Expand All @@ -76,7 +76,7 @@ public function provideOptions(): array
(new ManifestOptions())
->setEnclosure('_')
->setDelimiter('|')
->setColumnMetadata((object)[
->setColumnMetadata((object) [
'123456' => [
[
'value' => 'Int column name',
Expand Down Expand Up @@ -132,7 +132,7 @@ public function provideOptions(): array
->setEnclosure('_')
->setDelimiter('|')
->setManifestType('output')
->setSchema(new ManifestOptionsSchema(
->addSchema(new ManifestOptionsSchema(
'id',
[
'base' => ['type' => 'INTEGER', 'length' => '11', 'default' => '123'],
Expand All @@ -141,7 +141,7 @@ public function provideOptions(): array
false,
true,
null,
['KBC.description' => 'Primary key column']
['KBC.description' => 'Primary key column'],
))
->setDestination('my.table')
->setIncremental(true)
Expand Down Expand Up @@ -290,7 +290,7 @@ function (): void {
true,
);
(new ManifestOptions())
->setSchema($schema)
->addSchema($schema)
->setColumns(['id', 'name']);
},
],
Expand All @@ -299,7 +299,7 @@ function (): void {
function (): void {
(new ManifestOptions())
->setColumns(['id', 'name'])
->setSchema(new ManifestOptionsSchema(
->addSchema(new ManifestOptionsSchema(
'id',
['base' => ['type' => 'INTEGER', 'length' => '11', 'default' => '123']],
false,
Expand All @@ -317,7 +317,7 @@ function (): void {
true,
);
(new ManifestOptions())
->setSchema($schema)
->addSchema($schema)
->setMetadata([
['key' => 'sample', 'value' => 'data'],
]);
Expand All @@ -333,7 +333,7 @@ function (): void {
true,
);
(new ManifestOptions())
->setSchema($schema)
->addSchema($schema)
->setColumnMetadata([
'id' => [
['key' => 'description', 'value' => 'ID column'],
Expand Down

0 comments on commit efee749

Please sign in to comment.