test(constructeur) : update test helpers and MCP tests for ConstructeurLinks
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -30,9 +30,7 @@ class ComposantsCrudToolTest extends AbstractApiTestCase
|
||||
$modelType = $this->createModelType(name: 'Type Composant', code: 'TC-001', category: ModelCategory::COMPONENT);
|
||||
$composant = $this->createComposant(name: 'Composant Gamma', type: $modelType);
|
||||
|
||||
// Add constructeur to composant
|
||||
$composant->addConstructeur($constructeur);
|
||||
$this->getEntityManager()->flush();
|
||||
$this->createComposantConstructeurLink($composant, $constructeur);
|
||||
|
||||
$session = $this->createMcpClient('ROLE_VIEWER');
|
||||
|
||||
|
||||
@@ -30,9 +30,7 @@ class MachinesCrudToolTest extends AbstractApiTestCase
|
||||
$constructeur = $this->createConstructeur(name: 'Fournisseur M');
|
||||
$machine = $this->createMachine(name: 'Machine Gamma', site: $site, reference: 'REF-M001');
|
||||
|
||||
// Add constructeur to machine
|
||||
$machine->addConstructeur($constructeur);
|
||||
$this->getEntityManager()->flush();
|
||||
$this->createMachineConstructeurLink($machine, $constructeur);
|
||||
|
||||
$session = $this->createMcpClient('ROLE_VIEWER');
|
||||
|
||||
|
||||
@@ -30,9 +30,7 @@ class PiecesCrudToolTest extends AbstractApiTestCase
|
||||
$modelType = $this->createModelType(name: 'Type Piece', code: 'TP-001', category: ModelCategory::PIECE);
|
||||
$piece = $this->createPiece(name: 'Piece Gamma', reference: 'REF-001', type: $modelType);
|
||||
|
||||
// Add constructeur to piece
|
||||
$piece->addConstructeur($constructeur);
|
||||
$this->getEntityManager()->flush();
|
||||
$this->createPieceConstructeurLink($piece, $constructeur);
|
||||
|
||||
$session = $this->createMcpClient('ROLE_VIEWER');
|
||||
|
||||
|
||||
@@ -30,9 +30,7 @@ class ProductsCrudToolTest extends AbstractApiTestCase
|
||||
$modelType = $this->createModelType(name: 'Type Produit', code: 'TP-001', category: ModelCategory::PRODUCT);
|
||||
$product = $this->createProduct(name: 'Product Gamma', reference: 'REF-001', type: $modelType);
|
||||
|
||||
// Add constructeur to product
|
||||
$product->addConstructeur($constructeur);
|
||||
$this->getEntityManager()->flush();
|
||||
$this->createProductConstructeurLink($product, $constructeur);
|
||||
|
||||
$session = $this->createMcpClient('ROLE_VIEWER');
|
||||
|
||||
|
||||
Reference in New Issue
Block a user