Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8779519
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 13, 20262026-06-13T19:48:31+00:00 2026-06-13T19:48:31+00:00

I got it working! I literally translated the Java here into Scala line by

  • 0

I got it working! I literally translated the Java here into Scala line by line:

https://github.com/junit-team/junit/blob/master/doc/ReleaseNotes4.8.md

Mostly it meant doing Array(classOf[ClassName]), removing “public” keywords, etc. My IntelliJ IDE helped a lot with suggestions.


I want to be able to run categories of tests, so I might tag one class of tests as “Version2dot3” and “SlowTest” and then be able to run just “slow tests”, or run “slow tests AND 2.3 tests”.

I’ve been trying to adapt this article to my Scala tests:

http://weblogs.java.net/blog/johnsmart/archive/2010/04/25/grouping-tests-using-junit-categories-0

I have a basic shell setup that almost works, but I’m getting java.lang.Exception: No runnable methods errors when I try to run the testSuite.

Ideas? I’ve successfully been able to run only certain test classes with SuiteClasses, but have not been able to run categories of tests (@Category annotation).

import org.junit.experimental.categories.{Categories, Category}
import org.junit.runners.Suite.SuiteClasses
import org.scalatest.FunSuite
import org.junit.runner.RunWith
import org.scalatest.junit.JUnitRunner

@RunWith(classOf[JUnitRunner])
@Category(Array(classOf[SlowTests]))
class FunSuiteTest extends FunSuite with DemoHelpers {
  test("demoTest1") {
    println("\n\nrunning DemoTest1...\n\n")
  }
}

@RunWith(classOf[JUnitRunner])
@Category(Array(classOf[SlowTests]))
class FunSuiteTest2 extends FunSuite with DemoHelpers {
  test("demoTest2") {
    println("\n\nrunning DemoTest2...\n\n")
  }
}

@RunWith(classOf[Categories])
@SuiteClasses(Array(classOf[SlowTests]))
class testSuite {

}
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-13T19:48:33+00:00Added an answer on June 13, 2026 at 7:48 pm

    Translate the Java here into Scala line by line:

    https://github.com/junit-team/junit/blob/master/doc/ReleaseNotes4.8.md

    Mostly it means doing Array(classOf[ClassName]), removing “public” keywords, etc.

    The IntelliJ IDE with the Scala plugin helps a lot with suggestions.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I got a working server in C# and a working client in Java (Android).
I am new to C#. Here is a hard-coded thing I got working: InputProperty
I've got (working) application done with ttk. It uses self-created module for showing a
At the moment, I've got working: public void logowanie() { int x=5,y=5; ... }
Update: Got this working by disabling CodeIgniter Profiler which was interfering with the Ajax
Has anyone got this working in a web application? No matter what I do
I've got Drupal working on a shared host, and I uploaded some modules from
I've got ELMAH working on my (Cassini) development server, and was quite happy with
I installed TeamCity and got it working against my project. However, I have since
This unix command I haven't got quite working on Mac yet - any ideas

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.