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 8285099
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 8, 20262026-06-08T11:22:04+00:00 2026-06-08T11:22:04+00:00

We usually write lots of tests and execute them frequently in Eclipse. Furthermore, we

  • 0

We usually write lots of tests and execute them frequently in Eclipse. Furthermore, we use Maven and later on Jenkins, which also run the tests. Every now and then we run into a situation where it makes a difference whether we test each test method, a whole test class or an entire package at once (meaning tests suddenly become red).

Consider static fields that are initialised already, jobs that keep running unintentionally, test methods are executed in a rather random order, … In other words there are plenty of situations where tests can interfere each other. Obviously we strive to write the methods in a way that all of the above doesn’t matter/happen and all is green no matter what the circumstances are.

I don’t know how the aforementioned products actually run the tests, but it seems that the JVM is launched, then all selected tests (a method, a class or a project) are done and after that the JVM shuts down. I haven’t seen an option that allows me to run the tests in all three possible ways automatically.

My questions now are:

  • How do you deal with it?
  • Do you actually consider this a problem?
  • 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-08T11:22:05+00:00Added an answer on June 8, 2026 at 11:22 am

    Tests should not depend on each other and not affect other tests. If you run into a situation where a test fails – you should find the reason and eliminate it.

    I only once had a situation where I needed to fork the JVM for each test. This can be done by using the forkMode property of the maven-surefire-plugin.

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

Sidebar

Related Questions

I am a Ph.D student, and I usually write articles which are later proof-read
I usually write python in emacs. I'll often want to re-evaluate my file, which
I write a lot of .NET based plug-ins for other programs which are usually
We usually write stored procedures on the database which accepts xml and returns result
I write lots of little libraries and modules and usually these libraries and modules
I usually write scripts for Illustrator and save them in the scripts folder. Then
I usually write (smallish) games in Java using a main 'while' loop somewhat like
I usually write something like this: <mx:VBox height=100% width=155> <mx:Button label=b1 width=100%/> <mx:Buttonlabel=b2 width=100%/>
When I write an SQL statement, I usually write it like this SELECT COUNT(*)
Usually i write my where statements as WHERE key=@0 then add a param. Now

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.