Ad
  • Custom User Avatar

    This comment is hidden because it contains spoiler information about the solution

  • Custom User Avatar

    I had to click Train to figure out the real task here. The best description of this problem is hidden away in some comment in the code setup:

    # return array of suspects with illegal items in their pockets
    
  • Custom User Avatar

    As far as the kata is right now the design is bad. Values of two semantics are mixed together with no way to tell between the both (not to mention exluding the option to have a price deduction of less than a dollar).

  • Custom User Avatar

    The result is suspect to floating point errors because no rounding is specified. e.g:

    should return 1 for order {:all=>100} and coupon {:value=>-0.99} -  Expected: 1, instead got: 1.0000000000000009
    
  • Custom User Avatar

    Order value should not be negative and should be rounded to two decimal points.

    The Order value should be rounded to two decimal points part is not tested.

  • Custom User Avatar

    Needs random tests.

  • Custom User Avatar

    I suggest replacing the word 'set' with the word 'list' in the description.

    The word 'set' has a particular meaning: "a collection of unordered values with no duplicates"
    and what is being described is a list of numbers which does include duplicates.