[FIX] Fix the issue withe percu.

This commit is contained in:
NADAL Jean-Baptiste
2026-09-15 12:11:32 +02:00
parent 71d3b71362
commit 46b2d0630e
7 changed files with 116 additions and 17 deletions
+11
View File
@@ -693,6 +693,17 @@ class APITest {
$this->test('Upload sup combined returns 200', $supUp['code'] === 200);
$this->test('Upload sup combined filename', str_contains($supUp['body']['path'] ?? '', 'contrebasse-1+clarinette-1.pdf'));
// Percussion parts are named after the real instrument(s)
$perUp = $this->multipartRequest("admin/scores/$scoreId/upload", [
['name' => 'file', 'file' => $tmpPdf],
['name' => 'piece', 'data' => '1'],
['name' => 'instrument', 'data' => 'per'],
['name' => 'version', 'data' => '1'],
['name' => 'combined', 'data' => 'glockenspiel-1+xylophone-1'],
]);
$this->test('Upload per combined returns 200', $perUp['code'] === 200);
$this->test('Upload per combined filename', str_contains($perUp['body']['path'] ?? '', 'glockenspiel-1+xylophone-1.pdf'));
// Instruments (list + filter)
$instr = $this->request('GET', "scores/$scoreId/instruments");
$this->test('Instruments returns 200', $instr['code'] === 200);