Assertions - getting striked off as I type | Selenium Forum
M
Posted on 04/11/2016
Please check why I am getting assertions striked - Assert.assertEquals comes as striked

package TestCases;

import org.junit.Test;

import junit.framework.Assert;

public class UnderstandingAssertions {

@Test
public void testFriendlistfacebook(){
int actualfriendlistfacebook = 100;
int expectedfriendlistfacebook =101;

/*if(actualfriendlistfacebook == expectedfriendlistfacebook){
System.out.println("Pass");
}else{
System.out.println("Fail");
}*/

Assert.assertEquals(expectedfriendlistfacebook, actualfriendlistfacebook);


}

M
Replied on 08/11/2016

use this assertions.

https://www.tutorialspoint.com/junit/junit_using_assertion.htm