| { |
| "absolute_id": 286, |
| "persona": "Backend Developer", |
| "task": "Based on a total of 5 duplicate test files IntegrationTest_1.java~IntegrationTest_5.java in the integration test, first analyze the semantic association of the file content (all are /api/v1/entities endpoint CRUD tests), extract the general logic abstraction into the BaseEntityIntegrationTest base class (derived new abstract class files); secondly, 5 Allocate differentiated test dimensions (forward process/boundary value/abnormal scenario/concurrency/data consistency) to each test class, supplement corresponding test cases and implement data isolation, timeout assertion, request header verification; finally generate a complete refactored test code package (including base class + 5_differentiated test classes_output is EntityIntegrationTest_Suite.txt Save it to the /test case/refactoring results/ directory, and generate test_refactoring_notes.txt at the same time, clarifying the responsibilities of each test class, use case coverage, and reference relationships between files (code references of base class → subclass).", |
| "task_diff": "medium", |
| "output_files": [ |
| "EntityIntegrationTest_Suite.txt", |
| "test_refactoring_notes.txt" |
| ], |
| "rubrics": [ |
| "Does EntityIntegrationTest_Suite.txt contain the BaseEntityIntegrationTest abstraction base class, which includes MockMvc injection, the base_path constant, the generateTestId method, the getRequestWithHeaders method, the assertResponseTime method, and 5 generic CRUD methods?", |
| "Does EntityIntegrationTest_Suite.txt contain a total of 6 complete Java class files (1 base class + 5 test subclasses)?", |
| "Are two abstract methods setupTestData and cleanupTestData defined in BaseEntityIntegrationTest to reserve extension interfaces for subclasses?", |
| "Did all request methods add X-Request-ID and Content-Type request headers via getRequestWithHeaders?", |
| "Are all responses asserting a response time ≤ 500ms via assertResponseTime?", |
| "Does IntegrationTest_1 inherit from BaseEntityIntegrationTest and is responsible for forward process testing, including no less than 4 forward test cases?", |
| "Does IntegrationTest_2 inherit BaseEntityIntegrationTest, and the responsibility is boundary value testing, including 6 boundary test cases with empty name, maximum length name, overlong name, ID 0, overlarge ID, and special characters?", |
| "Does IntegrationTest_3 inherit BaseEntityIntegrationTest, and the responsibility is exception scenario testing, including non-existent ID query, invalid JSON, missing required fields, illegal status, duplicate deletion, update non-existent, missing Content-Type A total of 7 exception test cases?", |
| "Does each test case dynamically generate a unique test ID by combining the generateTestId with the UUID to achieve data isolation between tests?", |
| "test_refactoring_notes.txt Is the inheritance reference relationship diagram of base class → subclass \"1 to 5\" clearly described?", |
| "test_refactoring_notes.txt Are the responsibilities and complete use case list of each test class clearly marked?", |
| "test_refactoring_notes.txt Does the table list the three engineering optimization points of data isolation, timeout assertion, and request header verification?", |
| "Does the concurrent test method for IntegrationTest_4 have a 3000ms timeout wait set and an assertion success rate of ≥ 95%?", |
| "Does the count consistency test of IntegrationTest_5 verify that the total number increases by N after N entities are created, and the original value is restored after deletion?", |
| "Have all five test subcategories removed the original duplicate code, leaving only differentiated test cases and no code redundancy?", |
| "Do generic CRUD methods for base class encapsulation (createEntity, getEntityById, getAllEntities, updateEntity, deleteEntity) each include a response time assertion?", |
| "test_refactoring_notes.txt Has the original question been recorded: 5 copies of completely duplicated code, and the code volume is reduced by about 60% after refactoring?", |
| "Are all the code guide packages in EntityIntegrationTest_Suite.txt complete and grammatically correct and can be compiled with mvn test?" |
| ], |
| "rubric_types": [ |
| "Outcome Evaluation", |
| "Basic Evaluation", |
| "Outcome Evaluation", |
| "Outcome Evaluation", |
| "Outcome Evaluation", |
| "Outcome Evaluation", |
| "Outcome Evaluation", |
| "Outcome Evaluation", |
| "Process Evaluation", |
| "Basic Evaluation", |
| "Basic Evaluation", |
| "Basic Evaluation", |
| "Process Evaluation", |
| "Outcome Evaluation", |
| "Process Evaluation", |
| "Outcome Evaluation", |
| "Basic Evaluation", |
| "Outcome Evaluation" |
| ], |
| "file_dep_graph": [], |
| "data_manifest": [ |
| { |
| "filename": "IntegrationTest_1.java", |
| "stored_relpath": "data/3af943bc3d3e41d8_IntegrationTest_1.java" |
| }, |
| { |
| "filename": "IntegrationTest_2.java", |
| "stored_relpath": "data/d2ab233b9c869033_IntegrationTest_2.java" |
| }, |
| { |
| "filename": "IntegrationTest_3.java", |
| "stored_relpath": "data/a25d3a9d6258e64d_IntegrationTest_3.java" |
| }, |
| { |
| "filename": "IntegrationTest_4.java", |
| "stored_relpath": "data/2933c0d23f10c815_IntegrationTest_4.java" |
| }, |
| { |
| "filename": "IntegrationTest_5.java", |
| "stored_relpath": "data/5bd555fe4f9d337b_IntegrationTest_5.java" |
| } |
| ], |
| "tested_capabilities": [ |
| "Workspace Exploration", |
| "Task-Providing File Utilization", |
| "Lineage Tracing", |
| "Semantic Content Relations Understanding" |
| ] |
| } |
|
|