mirror of
https://github.com/ThrowTheSwitch/CMock.git
synced 2026-09-13 13:49:56 +00:00
updated the documents to include all plugins and some other minor tweaks.
This commit is contained in:
@@ -0,0 +1,10 @@
|
|||||||
|
Welcome to CMock.
|
||||||
|
|
||||||
|
* Not sure what you're doing?
|
||||||
|
** The docs are in /docs
|
||||||
|
* Interested in our MIT-style license?
|
||||||
|
** That's in /docs too
|
||||||
|
* Are there examples?
|
||||||
|
** Try /examples
|
||||||
|
* Any other resources to check out?
|
||||||
|
** Sure. How about ThrowTheSwitch.org
|
||||||
Binary file not shown.
Binary file not shown.
+27
-3
@@ -1,4 +1,4 @@
|
|||||||
[All code is copyright © 2007-2010 Cmock Project
|
[All code is copyright © 2007-2014 Cmock Project
|
||||||
by Mike Karlesky, Mark VanderVoord, and Greg Williams.
|
by Mike Karlesky, Mark VanderVoord, and Greg Williams.
|
||||||
|
|
||||||
This Documentation Is Released Under a Creative Commons 3.0
|
This Documentation Is Released Under a Creative Commons 3.0
|
||||||
@@ -144,6 +144,30 @@ returns or a single value to always return, whichever you prefer.
|
|||||||
* `retval func(params)` => `void func_IgnoreAndReturn(retval_to_return)`
|
* `retval func(params)` => `void func_IgnoreAndReturn(retval_to_return)`
|
||||||
|
|
||||||
|
|
||||||
|
Ignore Args:
|
||||||
|
------------
|
||||||
|
|
||||||
|
This plugin adds the ability to specify specifc arguments to ignore
|
||||||
|
for a function, instead of ignoring all the arguments or the entire
|
||||||
|
function call, as the Ignore plugin supports. This will create a function
|
||||||
|
for each argument and each function.
|
||||||
|
|
||||||
|
* `void func(params)` => `void func_IgnoreArg_paramName(void)`
|
||||||
|
|
||||||
|
|
||||||
|
ReturnThruPtr:
|
||||||
|
--------------
|
||||||
|
|
||||||
|
This plugin adds a number of options for returning data through arguments
|
||||||
|
that are pointers. This is fled separately from the Expect/Ignore call, so
|
||||||
|
you will want to issue one of those calls each time as well. This will only
|
||||||
|
create an extra call for arguments that are pointers. It will create one per
|
||||||
|
pointer argument.
|
||||||
|
|
||||||
|
* `void func(param1)` => `void func_ReturnThruPtr_paramName(val_to_return)`
|
||||||
|
* => `void func_ReturnArrayThruPtr_paramName(cal_to_return, len)`
|
||||||
|
* => `void func_ReturnMemThruPtr_paramName(val_to_return, size)`
|
||||||
|
|
||||||
Running CMock
|
Running CMock
|
||||||
=============
|
=============
|
||||||
|
|
||||||
@@ -262,8 +286,8 @@ Defined in the yaml file, they look more like this:
|
|||||||
|
|
||||||
* `:plugins`:
|
* `:plugins`:
|
||||||
An array of which plugins to enable. 'expect' is always active. Also
|
An array of which plugins to enable. 'expect' is always active. Also
|
||||||
available currently are `:ignore,` `:array,` `:cexception,` and
|
available currently are `:ignore,` `:ignore_args,` `:array,`
|
||||||
`:callback:
|
`:cexception,` `:callback,` and `:return_thru_ptr`
|
||||||
|
|
||||||
* `:treat_as`:
|
* `:treat_as`:
|
||||||
The `:treat_as` list is a shortcut for when you have created typedefs
|
The `:treat_as` list is a shortcut for when you have created typedefs
|
||||||
|
|||||||
+1
-1
@@ -1,4 +1,4 @@
|
|||||||
Copyright (c) 2007 Mike Karlesky, Mark VanderVoord, Greg Williams
|
Copyright (c) 2007-14 Mike Karlesky, Mark VanderVoord, Greg Williams
|
||||||
|
|
||||||
Permission is hereby granted, free of charge, to any person
|
Permission is hereby granted, free of charge, to any person
|
||||||
obtaining a copy of this software and associated documentation
|
obtaining a copy of this software and associated documentation
|
||||||
|
|||||||
Reference in New Issue
Block a user