Test: planned count or done_testing()
Greetings, While testing various bugs, frequently conflicts come up with tests where one bug adds a test, and another adds two tests, and the count difference causes the need to correct the test plan count while rebasing. So, I was wondering if perhaps when adding tests we could switch to just done_testing() and not actually use test counts, so adding and removing tests will not need fixing of line or lines that have a plan count. Thoughts? GPML, Mark Tompsett
Less strict, but more pragmatic. I think we spend more time on rebasing test counts than we will probably spend on checking tests that passed but should have failed on counts. We can always add a count where we really want it. No objection from me.
I do not think it's a good idea, it can hide bugs [examples needed]
We can always add a count where we really want it.
When do you know it is needed? :) We could also use use Test::More plan => $number_of_tests; BEGIN{ $number_of_tests += 1 }; subtest "first subtest" => sub { ok(); } BEGIN{ $number_of_tests += 1 }; subtest "second subtest" => sub { ok(); } But I am not a fan of this but we avoid useless conflicts and keep the plan. refs: - https://perlmaven.com/done-testing - https://stackoverflow.com/questions/690342/why-do-i-need-to-know-how-many-te... (best answer disagrees with me) Cheers, Jonathan On Wed, 15 Nov 2017 at 11:18 Marcel de Rooy <M.de.Rooy@rijksmuseum.nl> wrote:
Less strict, but more pragmatic.
I think we spend more time on rebasing test counts than we will probably spend on checking tests that passed but should have failed on counts. We can always add a count where we really want it.
No objection from me.
_______________________________________________ Koha-devel mailing list Koha-devel@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-devel website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
On 14/11/17 05:43, Mark Tompsett wrote:
Greetings, While testing various bugs, frequently conflicts come up with tests where one bug adds a test, and another adds two tests, and the count difference causes the need to correct the test plan count while rebasing. So, I was wondering if perhaps when adding tests we could switch to just done_testing() and not actually use test counts, so adding and removing tests will not need fixing of line or lines that have a plan count. Thoughts? GPML, Mark Tompsett
hmm, i can't think of a reason why this would be a bad idea.. anyone? ..so +1 from me :0)
+1 from me. -- Indranil Das Gupta L2C2 Technologies Phone : +91-98300-20971 Blog : http://blog.l2c2.co.in IRC : indradg on irc://irc.freenode.net Twitter : indradg On Thu, Nov 16, 2017 at 12:29 PM, Mason James <mtj@kohaaloha.com> wrote:
On 14/11/17 05:43, Mark Tompsett wrote:
Greetings,
While testing various bugs, frequently conflicts come up with tests where one bug adds a test, and another adds two tests, and the count difference causes the need to correct the test plan count while rebasing. So, I was wondering if perhaps when adding tests we could switch to just done_testing() and not actually use test counts, so adding and removing tests will not need fixing of line or lines that have a plan count. Thoughts?
GPML, Mark Tompsett
hmm, i can't think of a reason why this would be a bad idea.. anyone?
..so +1 from me :0)
_______________________________________________ Koha-devel mailing list Koha-devel@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-devel website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
+1 from me as well! Kyle <https://secure2.convio.net/cffh/site/Donation2?df_id=1395&FR_ID=4715&PROXY_ID=2706639&PROXY_TYPE=20&1395.donation=form1&s_src=CHORUS&s_subsrc=CHAADOEB> http://www.kylehall.info ByWater Solutions ( http://bywatersolutions.com ) Meadville Public Library ( http://www.meadvillelibrary.org ) Crawford County Federated Library System ( http://www.ccfls.org ) On Thu, Nov 16, 2017 at 2:45 AM, Indranil Das Gupta <indradg@l2c2.co.in> wrote:
+1 from me.
-- Indranil Das Gupta L2C2 Technologies
Phone : +91-98300-20971 <+91%2098300%2020971> Blog : http://blog.l2c2.co.in IRC : indradg on irc://irc.freenode.net Twitter : indradg
On Thu, Nov 16, 2017 at 12:29 PM, Mason James <mtj@kohaaloha.com> wrote:
On 14/11/17 05:43, Mark Tompsett wrote:
Greetings,
While testing various bugs, frequently conflicts come up with tests where one bug adds a test, and another adds two tests, and the count difference causes the need to correct the test plan count while rebasing. So, I was wondering if perhaps when adding tests we could switch to just done_testing() and not actually use test counts, so adding and removing tests will not need fixing of line or lines that have a plan count. Thoughts?
GPML, Mark Tompsett
hmm, i can't think of a reason why this would be a bad idea.. anyone?
..so +1 from me :0)
_______________________________________________ Koha-devel mailing list Koha-devel@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-devel website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
_______________________________________________ Koha-devel mailing list Koha-devel@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-devel website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
participants (6)
-
Indranil Das Gupta -
Jonathan Druart -
Kyle Hall -
Marcel de Rooy -
Mark Tompsett -
Mason James