Note: in this case, the behavior is even asynchronous, and thus a tool "asyncFn" is used to keep the test as simple as possible.
Co-authored-by: Janne Savolainen <janne.savolainen@live.fi>
Signed-off-by: Mikko Aspiala <mikko.aspiala@gmail.com>
This is a kludge because extraction of segregated interface for KubeObject is very difficult. This commit uses actual instance of KubeObject instead as a fake.
Signed-off-by: Janne Savolainen <janne.savolainen@houston-inc.com>
Key changes were:
- Introduction of dependencies as interfaces to permit stubbing in general (Dependency Inversion Principle)
- Introduction of segregated interfaces to only require stubbing of minimal stuff (Interface Segregation Principle)
Signed-off-by: Janne Savolainen <janne.savolainen@houston-inc.com>