12

I know this is a silly question but I would like to know how to execute own test cases in a Codility test. I can add several test inputs to my function but I don't know how execute it using these values.

I appreciate any input.

Aurelio
  • 24,702
  • 9
  • 60
  • 63
ctowers
  • 131
  • 1
  • 1
  • 5

1 Answers1

5

After adding test cases you can simply click "run" - it will run your function on default tests and your tests too. Return value of your function will be visible in console under the run button.

(Remember that Codility doesn't check your answers on your own tests!)

Jaszczur
  • 156
  • 4
  • 2
    So there is no way to put in the expected answers for your test cases? – wim Apr 12 '15 at 11:11
  • 6
    @wim Now, there is no way to add desired output; but I've passed your suggestion directly to Codility team. IMHO it would be useful, so I hope they will implement this soon. – Jaszczur May 08 '15 at 12:13
  • 4
    It would also be super useful if there was a way to use the performance test cases. Like is there a way to generate a test case for the big data test cases? – Sandy D. Dec 27 '17 at 20:43
  • 1
    I see this was posted 2015... IT IS 2021 and codility still does not show the expected result of your test casest. Very unhelpful. HackerRank and leetcode would let you know, though. – punsoca Dec 02 '21 at 20:17