Code Monkey home page Code Monkey logo

Comments (3)

GoogleCodeExporter avatar GoogleCodeExporter commented on July 26, 2024
The problem in this case was the shunit_match_=`expr "${shunit_condition_}" : 
'\([0-9]*\)'` which returned a 1. i attached an || true to ensure that return 
value is always 0 (since it won't be evaluated by the script).

I also fixed the problem for the AssertEquals and AssertNotEquals functions. 
there the problem came frmo failNotEquals.

One remaining problem is that an `assertTrue 1` will still cause the crash 
since the assertion function returns failure in this case. I'm not sure if this 
is a responsibility of the assetion function or the caller that should check 
the return value. I tend to give the responsibility to the caller.

I did not write test yet because I'm not sure how this behaviour could be 
tested.

Original comment by [email protected] on 13 Sep 2013 at 11:49

Attachments:

from shunit2.

alexharv074 avatar alexharv074 commented on July 26, 2024

@kward this is quite a gotcha. Is this issue just waiting on someone to rebase the above patch on the latest shunit2 in master?

from shunit2.

williamdes avatar williamdes commented on July 26, 2024

Fixed by 6f6a642

from shunit2.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.