Ad
  • Default User Avatar

    You're right there is something weird: I always thought that this import was necessary, I solved troubles sometimes by adding it, but in the meantime I saw implementations working without it. So... I dunno... :-/

  • Custom User Avatar

    @B4B.

    It is always present in the prefilled code, between others, so you never noticed it, but this time, you paste your full code from your IDE in replacement (I suppose) so it was lacking this line.

    On the contrary. I notice everything! My habit is to remove all imports that seem to be redundant so I saw this one, and removed it. I never had this problem before, so why now? I'm sure I've removed the same import from other Java Katas and nobody mentioned it before... I can remove it in the Kata editor and everything works fine with it commented out for me. (??)

  • Default User Avatar

    resolve what? The issue? I did! ;)

  • Default User Avatar

    Um, how do I resolve it? It's not letting me edit my comment because you replied, I am assuming.

  • Default User Avatar

    Works perfectly fine in java, on my side. Close the issue.

  • Default User Avatar

    Oops, I didn't see this one. Corrected. Should be good, now.

  • Default User Avatar

    Works in JS. This was fun. Good idea. :)

  • Default User Avatar

    Hey, can anyone check if the java version is broken? I can play with the js version, but pretty sure the Java one is broken.

  • Custom User Avatar

    rename howmanyBees > howManyBees

  • Default User Avatar

    Blind4Basics, it is still not working for me. Is there anything else I need to do? I placed the import line in the second box (sample tests), and I am still getting the errors. I don't normally edit test cases but I would assume it takes effect right away.

  • Default User Avatar

    Hi DM!

    This is needed so that CW can run/import the Junit test module. It is always present in the prefilled code, between others, so you never noticed it, but this time, you paste your full code from your IDE in replacement (I suppose) so it was lacking this line. I had the problem not so long ago, doing some translations.

    Cheers!

  • Custom User Avatar

    Hi B4B. Can you explain or reference me why that is needed. I don't think I ever imported it for other Kata either.. :-|

  • Default User Avatar

    this line was missing : import org.junit.runners.JUnit4;

    I tried to update the kata, but CW's server has some issue on is side, for now. Just had this line, it will make the same tests work. But you'll have to wait for a correction to pass the test cases (same problem there)

    EDIT: corrected

  • Default User Avatar

    It does this even when I click reset and just have the default code.

  • Default User Avatar

    Sorry but is the Java version broken? My code runs in Netbeans perfectly, but on codewars I get this:
    Error: Command failed: javac -verbose -cp /home/codewarrior -d /home/codewarrior -sourcepath /home/codewarrior -cp /usr/local/groovy/lib/junit-4.12.jar:/usr/local/groovy/lib/hamcrest-core-1.3.jar /home/codewarrior/Dinglemouse.java /home/codewarrior/ExampleTests.java ./frameworks/java/CwRunListener.java
    [parsing started RegularFileObject[/home/codewarrior/Dinglemouse.java]]
    [parsing completed 46ms]
    [parsing started RegularFileObject[/home/codewarrior/ExampleTests.java]]
    [parsing completed 5ms]
    [parsing started RegularFileObject[./frameworks/java/CwRunListener.java]]
    [parsing completed 2ms]
    [search path for source files: /home/codewarrior]
    [search path for class files: /usr/lib/jvm/java-8-oracle/jre/lib/resources.jar,/usr/lib/jvm/java-8-oracle/jre/lib/rt.jar,/usr/lib/jvm/java-8-oracle/jre/lib/sunrsasign.jar,/usr/lib/jvm/java-8-oracle/jre/lib/jsse.jar,/usr/lib/jvm/java-8-oracle/jre/lib/jce.jar,/usr/lib/jvm/java-8-oracle/jre/lib/charsets.jar,/usr/lib/jvm/java-8-oracle/jre/lib/jfr.jar,/usr/lib/jvm/java-8-oracle/jre/classes,/usr/lib/jvm/java-8-oracle/jre/lib/ext/cldrdata.jar,/usr/lib/jvm/java-8-oracle/jre/lib/ext/sunec.jar,/usr/lib/jvm/java-8-oracle/jre/lib/ext/jaccess.jar,/usr/lib/jvm/java-8-oracle/jre/lib/ext/zipfs.jar,/usr/lib/jvm/java-8-oracle/jre/lib/ext/sunjce_provider.jar,/usr/lib/jvm/java-8-oracle/jre/lib/ext/sunpkcs11.jar,/usr/lib/jvm/java-8-oracle/jre/lib/ext/dnsns.jar,/usr/lib/jvm/java-8-oracle/jre/lib/ext/nashorn.jar,/usr/lib/jvm/java-8-oracle/jre/lib/ext/jfxrt.jar,/usr/lib/jvm/java-8-oracle/jre/lib/ext/localedata.jar,/usr/local/groovy/lib/junit-4.12.jar,/usr/local/groovy/lib/hamcrest-core-1.3.jar]
    [loading ZipFileIndexFileObject[/usr/lib/jvm/java-8-oracle/lib/ct.sym(META-INF/sym/rt.jar/java/lang/Object.class)]]
    [loading ZipFileIndexFileObject[/usr/local/groovy/lib/junit-4.12.jar(org/junit/Test.class)]]
    [loading ZipFileIndexFileObject[/usr/local/groovy/lib/junit-4.12.jar(org/junit/Assert.class)]]
    [loading ZipFileIndexFileObject[/usr/local/groovy/lib/junit-4.12.jar(org/junit/runner/notification/Failure.class)]]
    [loading ZipFileIndexFileObject[/usr/local/groovy/lib/junit-4.12.jar(org/junit/runner/notification/RunListener.class)]]
    [loading ZipFileIndexFileObject[/usr/local/groovy/lib/junit-4.12.jar(org/junit/runner/Description.class)]]
    [loading ZipFileIndexFileObject[/usr/lib/jvm/java-8-oracle/lib/ct.sym(META-INF/sym/rt.jar/java/io/StringWriter.class)]]
    [loading ZipFileIndexFileObject[/usr/lib/jvm/java-8-oracle/lib/ct.sym(META-INF/sym/rt.jar/java/io/PrintWriter.class)]]
    [loading ZipFileIndexFileObject[/usr/lib/jvm/java-8-oracle/lib/ct.sym(META-INF/sym/rt.jar/java/lang/Throwable.class)]]
    [loading ZipFileIndexFileObject[/usr/lib/jvm/java-8-oracle/lib/ct.sym(META-INF/sym/rt.jar/java/lang/String.class)]]
    [loading ZipFileIndexFileObject[/usr/lib/jvm/java-8-oracle/lib/ct.sym(META-INF/sym/rt.jar/java/lang/annotation/Retention.class)]]
    [loading ZipFileIndexFileObject[/usr/lib/jvm/java-8-oracle/lib/ct.sym(META-INF/sym/rt.jar/java/lang/annotation/RetentionPolicy.class)]]
    [loading ZipFileIndexFileObject[/usr/lib/jvm/java-8-oracle/lib/ct.sym(META-INF/sym/rt.jar/java/lang/annotation/Target.class)]]
    [loading ZipFileIndexFileObject[/usr/lib/jvm/java-8-oracle/lib/ct.sym(META-INF/sym/rt.jar/java/lang/annotation/ElementType.class)]]
    [loading ZipFileIndexFileObject[/usr/lib/jvm/java-8-oracle/lib/ct.sym(META-INF/sym/rt.jar/java/lang/annotation/Annotation.class)]]
    [checking Dinglemouse]
    [loading ZipFileIndexFileObject[/usr/lib/jvm/java-8-oracle/lib/ct.sym(META-INF/sym/rt.jar/java/io/Serializable.class)]]
    [loading ZipFileIndexFileObject[/usr/lib/jvm/java-8-oracle/lib/ct.sym(META-INF/sym/rt.jar/java/lang/AutoCloseable.class)]]
    [loading ZipFileIndexFileObject[/usr/lib/jvm/java-8-oracle/lib/ct.sym(META-INF/sym/rt.jar/java/lang/System.class)]]
    [loading ZipFileIndexFileObject[/usr/lib/jvm/java-8-oracle/lib/ct.sym(META-INF/sym/rt.jar/java/io/PrintStream.class)]]
    [loading ZipFileIndexFileObject[/usr/lib/jvm/java-8-oracle/lib/ct.sym(META-INF/sym/rt.jar/java/lang/Appendable.class)]]
    [loading ZipFileIndexFileObject[/usr/lib/jvm/java-8-oracle/lib/ct.sym(META-INF/sym/rt.jar/java/io/Closeable.class)]]
    [loading ZipFileIndexFileObject[/usr/lib/jvm/java-8-oracle/lib/ct.sym(META-INF/sym/rt.jar/java/io/FilterOutputStream.class)]]
    [loading ZipFileIndexFileObject[/usr/lib/jvm/java-8-oracle/lib/ct.sym(META-INF/sym/rt.jar/java/io/OutputStream.class)]]
    [loading ZipFileIndexFileObject[/usr/lib/jvm/java-8-oracle/lib/ct.sym(META-INF/sym/rt.jar/java/io/Flushable.class)]]
    [loading ZipFileIndexFileObject[/usr/lib/jvm/java-8-oracle/lib/ct.sym(META-INF/sym/rt.jar/java/lang/Byte.class)]]
    [loading ZipFileIndexFileObject[/usr/lib/jvm/java-8-oracle/lib/ct.sym(META-INF/sym/rt.jar/java/lang/Character.class)]]
    [loading ZipFileIndexFileObject[/usr/lib/jvm/java-8-oracle/lib/ct.sym(META-INF/sym/rt.jar/java/lang/Short.class)]]
    [loading ZipFileIndexFileObject[/usr/lib/jvm/java-8-oracle/lib/ct.sym(META-INF/sym/rt.jar/java/lang/Long.class)]]
    [loading ZipFileIndexFileObject[/usr/lib/jvm/java-8-oracle/lib/ct.sym(META-INF/sym/rt.jar/java/lang/Float.class)]]
    [loading ZipFileIndexFileObject[/usr/lib/jvm/java-8-oracle/lib/ct.sym(META-INF/sym/rt.jar/java/lang/Integer.class)]]
    [loading ZipFileIndexFileObject[/usr/lib/jvm/java-8-oracle/lib/ct.sym(META-INF/sym/rt.jar/java/lang/Double.class)]]
    [loading ZipFileIndexFileObject[/usr/lib/jvm/java-8-oracle/lib/ct.sym(META-INF/sym/rt.jar/java/lang/Boolean.class)]]
    [loading ZipFileIndexFileObject[/usr/lib/jvm/java-8-oracle/lib/ct.sym(META-INF/sym/rt.jar/java/lang/Void.class)]]
    [loading ZipFileIndexFileObject[/usr/lib/jvm/java-8-oracle/lib/ct.sym(META-INF/sym/rt.jar/java/lang/Comparable.class)]]
    [loading ZipFileIndexFileObject[/usr/lib/jvm/java-8-oracle/lib/ct.sym(META-INF/sym/rt.jar/java/lang/CharSequence.class)]]
    [wrote RegularFileObject[/home/codewarrior/Dinglemouse.class]]
    [checking ExampleTests]
    [loading ZipFileIndexFileObject[/usr/lib/jvm/java-8-oracle/lib/ct.sym(META-INF/sym/rt.jar/java/lang/StringBuilder.class)]]
    [loading ZipFileIndexFileObject[/usr/lib/jvm/java-8-oracle/lib/ct.sym(META-INF/sym/rt.jar/java/lang/StringBuffer.class)]]
    /home/codewarrior/ExampleTests.java:23: error: cannot find symbol
    assertEquals("Nope", 5, Dinglemouse.howManyBees(_show(hive)));
    ^
    symbol: method howManyBees(char[][])
    location: class Dinglemouse
    /home/codewarrior/ExampleTests.java:33: error: cannot find symbol
    assertEquals("Nope", 7, Dinglemouse.howManyBees(_show(hive)));
    ^
    symbol: method howManyBees(char[][])
    location: class Dinglemouse
    [checking CwRunListener]
    [loading ZipFileIndexFileObject[/usr/lib/jvm/java-8-oracle/lib/ct.sym(META-INF/sym/rt.jar/java/util/Locale.class)]]
    [loading ZipFileIndexFileObject[/usr/lib/jvm/java-8-oracle/lib/ct.sym(META-INF/sym/rt.jar/java/io/Writer.class)]]
    [loading ZipFileIndexFileObject[/usr/lib/jvm/java-8-oracle/lib/ct.sym(META-INF/sym/rt.jar/java/io/File.class)]]
    [loading ZipFileIndexFileObject[/usr/lib/jvm/java-8-oracle/lib/ct.sym(META-INF/sym/rt.jar/java/lang/Throwable$PrintStreamOrWriter.class)]]
    [total 691ms]
    2 errors

  • Loading more items...