tests.mock_file

module docstring content more content

mock_function

mock_function(
param_a,
param_b=2)
A mock function returning a sum of param_a and param_b if positive numbers, else None

Parameters

param_a
int
A *test* _param_.
param_b
int | float
Another *test* _param_. | col A |: col B | |-------|--------| | boo | baa more content across broken line|

Returns

summed_number
int | float
The sum of _param_a_ and _param_b_.
None
None returned if values are negative.

Raises

ValueError
Raises value error if params are not numbers.

Notes

```python print(mock_function(1, 2)) # prints 3 ``` Random text _Random table_ | col A |: col B | |-------|--------| | boo | baa |

ParentClass

A parent class

Properties

parent_prop
str

Methods

ParentClass.__init__

ParentClass.__init__(
**kwargs)
Parent initialisation.

Parameters

**kwargs
Keyword args.

ChildClass

Inherits from ParentClass.

A child class

Properties

param_e

Methods

ChildClass.__init__

ChildClass.__init__(
param_c=1.1,
param_d=0.9,
**kwargs)
Child initialisation.

Parameters

param_c
float
Yet another test param.
param_d
float
And another.
**kwargs
Keyword args.

ChildClass.hello

ChildClass.hello(
A random class method returning "hello"

Returns

str
saying_hello
A string saying "hello"