> loading_
// To experience the new AI-powered test generation, navigate to the test file:
// File: tests/local_signing_test.ts
// 1. You'll find the original 'happy path' test case for a standard LoanSet transaction.
// it('should correctly sign and verify a standard LoanSet transaction', async () => { ... });
// 2. To generate new edge case tests, run the new test generation script from your terminal.
// This script prompts an LLM with the LoanSet transaction schema and constraints.
// $ npm run test:generate
// 3. The script will automatically add new Jest test blocks to `local_signing_test.ts`.
// Observe the newly generated tests for various failure modes:
// // Example of an AI-generated test for an invalid principal amount.
// it('should fail when PrincipalRequested is a negative value', async () => {
// const tx = { ...baseLoanSetTx, PrincipalRequested: "-1000" };
// // The test will assert that signing or submission throws an error.
// await expect(signAndSubmit(tx)).rejects.toThrow('Invalid principal amount');
// });
// // Example of a test for an incorrect signing sequence.
// it('should fail if a counterparty signature is applied to a non-autofilled blob', async () => {
// // Test logic here simulates the incorrect signing order...
// await expect(signIncorrectly(tx)).rejects.toThrow('Invalid signing sequence');
// });
// 4. Run the full test suite to see these new, AI-generated cases in action.
// $ npm test