3

I am using ceedling for unit testing in a firmware I am working on. I would like to see all command line option ceedling uses when invoking the compiler.

I tried to use the option --trace, but so for I have not found any difference.

ceedling test:all --trace

August Janse
  • 290
  • 1
  • 6
  • 18

2 Answers2

3

try:

ceedling verbosity[4] test:all

bd2357
  • 704
  • 9
  • 17
  • useful, but doesn't seem to do what I want, which is give me a trace of what mocks were called, in what order, in order to debug by tests/code – danmcb Feb 04 '22 at 09:10
  • I just use gdb for debugging a specific test. The mocking system will enforce order when you use _Expect variants and does not when you use _Ignore variants, I think there are options to change this behavior though. – bd2357 Feb 05 '22 at 16:01
0

If you are on a Windows machine, the command line args can be intercepted like this:

Create a little command line tool ShowArgs.exe that displays the given command line args in a message box.

Create a registry key in SOFTWARE\Microsoft\Windows NT\CurrentVersion\Image File Execution Options\Foo.exe whereas Foo.exe is the name of the compiler without the path.

Add a value with name debugger and value "" including the quotation marks, e.g.

SOFTWARE\Microsoft\Windows NT\CurrentVersion\Image File Execution Options\Foo.exe\debugger="C:\Temp\ShowArgs.exe"

Now ShowArgs.exe acts as the debugger for Foo.exe and is called instead. The first argument is the path to Foo.exe, all other arguments are the ones you are interested in.

Christoph
  • 3,322
  • 2
  • 19
  • 28
  • Thanks for your attention. But was looking for something more straightforward, like an option in ceedling configuration file... – Thomas Friesen Jul 11 '19 at 19:04
  • In the original unedited question you have been refering to an application that calls it in the correct way. My solution only shows what that application is doing, what exact command line arguments it uses in their call. Of course you would then simply use these arguments and delete the debugger registry key and the helper application. – Christoph Jul 18 '19 at 07:52