nasa / fpp

F Prime Prime: A modeling language for F Prime
https://fprime.jpl.nasa.gov
Apache License 2.0
49 stars 31 forks source link

[fpp-tools] Revise switches for C++ code gen #330

Closed bocchino closed 1 year ago

bocchino commented 1 year ago

Changes requested during the F Prime integration:

fpp-to-cpp

  1. When -u is enabled, only unit test base class code should be generated, not component autocode.
  2. Add a flag -a (automatic test setup) to govern the generation of TesterHelpers.cpp. When -a is present, TesterHelpers.cpp is generated when -u is present and -t is not present. Otherwise TesterHelpers.cpp is generated when -u and -t are both present.

fpp-filenames

  1. Add an -a flag and make the behavior match that of fpp-to-cpp.

fpp-depend

  1. Eliminate the -t option. If necessary in the next round of integration, we can write generated template files to separate files with the suffix .template. This may not be necessary, depending on how the integration is done.
  2. Have the -u flag write the unit test base class files (and only those files) to a separate file, instead of adding the unit test files to the autocoded files reported by -g.
  3. Add an -a flag. When -a is present,TesterHelpers.cpp is included with the autocode files reported by -u. Otherwise it is not so included.

Tasks

bocchino commented 1 year ago

@LeStarch FYI.