Results 1 to 2 of 2
  1. #1
    tcms is offline Member
    Join Date
    May 2013
    Rep Power

    Default Question about Assert Message

    Hi guys,

    I'am doing a test on a little program and I decide to make a testclass with Junit. I made an assertNotNull, but this assert receive two parameters (message, condition).

    My question is, what is the porpuse for the message parameter?


  2. #2
    cattox is offline Member
    Join Date
    Mar 2009
    Rep Power

    Default Re: Question about Assert Message

    That message will show after a test execution if that specific assertion fails. You can use it to show test variable values to debug possible problems for instance. or just to give some info on the test failure.

Similar Threads

  1. Question Message
    By coollucky in forum AWT / Swing
    Replies: 3
    Last Post: 12-03-2011, 04:50 PM
  2. probleme with assert statement
    By pierre in forum New To Java
    Replies: 3
    Last Post: 10-23-2009, 10:10 PM
  3. Java assert messages lost
    By DavidH in forum Eclipse
    Replies: 0
    Last Post: 08-09-2009, 06:51 PM
  4. Assert with an informative message
    By Java Tip in forum java.lang
    Replies: 0
    Last Post: 04-16-2008, 11:04 PM
  5. Assert - not showing any msg on console
    By ravian in forum New To Java
    Replies: 0
    Last Post: 11-16-2007, 03:20 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts