Op 15-9-2020 om 15:42 schreef Roelof Wobben via Pharo-users:
with: other count: testBlock
        |r|
        r := 0.
        self with: other do: [:x :y |
            (testBlock value: x value: y) ifTrue: [r := r + 1]].
        ^r


nope, all the test on a error are yellow and this two test on  counting are yellow.

test03_SingleLetterDifferentStrands
    | result |
    result := hammingCalculator distanceStrand1: 'G' strand2: 'T'.
    self assert: result equals:

gives 0 instead of 9.

and this one fails :

test05_LongDifferentStrands
    | result |
    result := hammingCalculator
        distanceStrand1: 'GGACGGATTCTG'
        strand2: 'AGGACGGATTCT'.
    self assert: result equals: 9

also this one gives 0 instead of 9.


Reply via email to