Skip to content

Try another approach to mark hanging generated tests #371

Closed
@EgorkaKulikov

Description

@EgorkaKulikov

Description

We mark hanging generated tests with @Timeout annotation but sometimes this annotation does not work properly.
For example, the test method for com.alibaba.fastjson.parser.DefaultJSONParser.accept sometimes significantly exceeds a timeout (see attached screen).

Visual proofs

image

Potential alternatives

Use another approach with assertTimeoutPreemptively
See https://stackoverflow.com/questions/57116801/how-to-fail-a-test-after-a-timeout-is-exceeded-in-junit-5/57116802#57116802 for more details.

Context

Migrated JIRA issue SAT-1671

Metadata

Metadata

Labels

comp-codegenIssue is related to code generatorctg-enhancementNew feature, improvement or change request

Type

No type

Projects

Status

Done

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions