Ad
  • Custom User Avatar

    Added a description

  • Custom User Avatar

    Unfortunately, I don't understand what you mean.

    I set conditions on this kata that are described.

    According to these conditions need to provide a working code.

    All these conditions are verified by tests

    Could you more details to explain what you mean, please?

  • Custom User Avatar

    The function doesn't return 1 and he expected result is not 2. 1 should equal 2 doesn't make sense.

  • Custom User Avatar

    I replaced the 'assert_true' with 'assert_equals'.

    Also, I do not understand what you mean about
    "Python: useless error messages:"

    1 should equal 2
    
  • Custom User Avatar

    Python: useless error messages:

    1 should equal 2
    
    "module 'codewars_test' has no attribute 'assert_true'" should equal 'Duplicate UIDs'
    
  • Custom User Avatar

    Made more numbers of tests

  • Custom User Avatar

    1 test is not adequate. Typically there should be around 100 tests.

  • Custom User Avatar

    Added description

  • Custom User Avatar

    Added test which has an array of various lengths with random values at the input

  • Custom User Avatar

    This code should be working with commands IDs
    Which IDs were input in the variable $uids they should be returned as an array certain configuration, this is one of the rules.
    You showed me an array in which there are values ​​that should not be there

  • Custom User Avatar

    The new test case return very cryptic expected/actual results because it is performing a complicated check, such as

    Failed asserting that two arrays are equal.
    Expected: Array (
        0 => 61
        1 => 110
        2 => 122
        3 => 124
        4 => 129
        5 => 139
        6 => 142
        7 => 152
        8 => 165
        9 => 179
        10 => 180
        11 => 214
        12 => 280
        13 => 312
        14 => 412
        15 => 445
        16 => 521
        17 => 712
        18 => 845
        19 => 911
        20 => 1219
    )
    Actual  : Array (
        0 => 1
        1 => 2
        2 => 3
        3 => 4
        4 => 5
        5 => 6
        6 => 7
        7 => 8
        8 => 9
        9 => 10
        10 => 11
        11 => 12
        12 => 13
        13 => 14
        14 => 15
        15 => 16
        16 => 17
        17 => 18
        18 => 19
        19 => 20
        20 => 21
        21 => 61
        22 => 110
        23 => 122
        24 => 124
        25 => 129
        26 => 139
        27 => 142
        28 => 152
        29 => 165
        30 => 179
        31 => 180
        32 => 214
        33 => 280
        34 => 312
        35 => 412
        36 => 445
        37 => 521
        38 => 712
        39 => 845
        40 => 911
        41 => 1219
    )
    

    Similarly, $this->assertTrue($unique); is not acceptable: if a test case fails there are no indication why it failed, which provides no useful (to downright misleading) feedback.

  • Custom User Avatar

    There are still no random tests. There was only a fixed test added.

  • Custom User Avatar

    The required input validation and what should be done about them (including throwing an exception with a specific message) should be all in the description. It is a key part of the spec.

  • Custom User Avatar

    After resolving the issues you need to republish the kata as well. It's currently in draft.

  • Custom User Avatar

    Developed and added a test that checks the compliance of input and output data.
    Corrected the description.

  • Loading more items...