On 01/20/2015 12:24 PM, Ancor Gonzalez Sosa wrote:
On 01/15/2015 05:53 PM, Ancor Gonzalez Sosa wrote:
This change introduced in our test:unit task has caused the tests in yast-yast2 to break. https://github.com/yast/yast-rake/commit/b00ca0e8c8208b05698675b0cb4752552de...
It's actually not a fault of the change in the task. The problem is that the tests are fragile because they pollute the global namespace in several ways. To be honest, I'd expect test from some other repositories to also break. Specially those written when we were still newbies with RSpec.
I did some changes in order to fix it but found another problem. Here is the patch, not intended to enhance or refactor the tests in any way, just to fix the minimum needed to make them run again. https://github.com/ancorgs/yast-yast2/commit/a5c09480081be09d894f2df3a8b36a3...
The weird thing is that I needed to introduce the line marked with a FIXME, which means that closing the default SCR is not as secure as all our tests assume. Looking at the yast2-core source code I'd say that the line is actually needed and we need to update quite some tests and the documentation. But it's the core, so of course I could be wrong.
That's the question I was trying to open in the phone call. We need to fix the broken tests in yast-yast2 and, for sure, in many other modules. How to proceed about the branches?
1) For maintenance branches like SLE12 and 13.2
Do we want to fix it?
They work with the version of yast-rake present in SLE12 and 13.2, but we cannot run "rake test:unit" for those branches with yast-rake>0.1.8 (in Tumbleweed at the moment).
2) For master
We have to fix it (not a question) but I think that fixing, for example, chrooting of SCR in every single module is wrong. We need to extract this functionality to the ruby bindings and then use them in the different modules. So in my opinion it's time to introduce RSpec helpers for SCR in the ruby bindings.
Like this, that I will commit to the proper repositories/branches once we answer the question above. https://github.com/ancorgs/yast-yast2/blob/29bfc826c0df463e77fbf0512c272167a...
3) For both (or only for master if we decide not to fix maint. branches)
Do we want to fix all the modules right now or only yast-yast2 and wait to see errors in the rest? Keep in mind that in order to experiment the errors you need to be using yast-rake>0.1.8 so the errors could persist unnoticed for quite some time unless we all update the dev tools.
Cheers.
-- Ancor González Sosa YaST Team at SUSE Linux GmbH -- To unsubscribe, e-mail: yast-devel+unsubscribe@opensuse.org To contact the owner, e-mail: yast-devel+owner@opensuse.org