-
Notifications
You must be signed in to change notification settings - Fork 12
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Mocked CAF::FileWriter attempts to create directories #139
Comments
quattor/CAF#202 should fix this. we should retest once that PR is tested and merged. |
quattor/CAF#202 may fix it but I checked the |
I manage to find the culprit... This is the mocked @stdweird any opinion? |
I had a look as the second solution (set |
how can i repoduce this issue? and have you tried the new filewriter? i have never had an issue with the original code; but we probably run NoAction=1 everywhere where we shouldn't. |
@stdweird I found this issue after your remark that we were abusing After thinking more at this problem, I think that what is wrong is to execute the original method in the mocked one. I've the feeling that the right approach is what I did with links: have a mocked version that is implementing the feature of the original one (like reporting diffs for example). An alternative could be to set |
ok, i see. but there are also cases where the mocking cannot be done, eg during the test profile CCM part. that needs fully functional FileWriter. it's also not a big issue as long as all compilation is triggered via the import hack. |
@stdweird your CCM use case is a reason I was proposing to set |
- Default can be overriden with $CAF::Object::NoAction=0 Fixes quattor#139
I just pushed a commit implement the |
- Default can be overriden with $Test::Quattor::NoAction=0 - Do not set noaction in CAF::FE::new() as it calls CAF::FW::new() Fixes quattor#139
- Default can be overriden with $Test::Quattor::NoAction=0 - Do not set noaction in CAF::FE::new() as it calls CAF::FW::new() Fixes quattor#139
- Default can be overriden with $Test::Quattor::NoAction=0 - Do not set noaction in CAF::FE::new() as it calls CAF::FW::new() - Ensure that $Test::Quattor::NoAction=0 in Test::Quattor:ProfileCache Fixes quattor#139
I believe this was closed by #160. |
I tried to remove
CAF::Object::NoAction=1
in a few unit tests, likewrite_grub2_config.t
in AIIaii-pxelinux
. This results in the following exception:This seems unexpected as
CAF::FileWriter
is supposed to be mocked...The text was updated successfully, but these errors were encountered: