mirror of
https://github.com/Part-DB/Part-DB-server.git
synced 2026-01-19 08:39:34 +00:00
Replace placeholder syntax for type synonyms to be more DX friendly
Co-authored-by: jbtronics <5410681+jbtronics@users.noreply.github.com>
This commit is contained in:
parent
3d3b1f276c
commit
a2f3ceb142
3 changed files with 28 additions and 23 deletions
|
|
@ -40,10 +40,11 @@ class RegisterSynonymsAsTranslationParametersTest extends KernelTestCase
|
|||
$placeholders = $this->listener->getSynonymPlaceholders();
|
||||
|
||||
$this->assertIsArray($placeholders);
|
||||
$this->assertSame('Part', $placeholders['{part}']);
|
||||
$this->assertSame('Parts', $placeholders['{{part}}']);
|
||||
//Lowercase versions:
|
||||
$this->assertSame('part', $placeholders['[part]']);
|
||||
$this->assertSame('parts', $placeholders['[[part]]']);
|
||||
// Curly braces for lowercase versions
|
||||
$this->assertSame('part', $placeholders['{part}']);
|
||||
$this->assertSame('parts', $placeholders['{{part}}']);
|
||||
// Square brackets for capitalized versions (with capital first letter in placeholder)
|
||||
$this->assertSame('Part', $placeholders['[Part]']);
|
||||
$this->assertSame('Parts', $placeholders['[[Part]]']);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue