UTBotCpp icon indicating copy to clipboard operation
UTBotCpp copied to clipboard

Reduce number of types used to initialize `FILE*` test input

Open tyuldashev opened this issue 3 years ago • 0 comments

Description

Input file preparation usually contains following line: struct _IO_FILE * fA = (UTBot::FILE *) fopen("../../../tests/src/A", "r");

Which uses three types to reference a file:

  • struct _IO_FILE
  • UTBot::FILE
  • std::FILE implicitly introduced as return type of fopen

If it's possible we could reduce cognitive load by using more concise expression. Ideally from my point of view it would look something like this:

FILE * fA = fopen("../../../tests/src/A", "r");

tyuldashev avatar Oct 18 '22 14:10 tyuldashev