Categories:
.NET (357)
C (330)
C++ (183)
CSS (84)
DBA (2)
General (7)
HTML (4)
Java (574)
JavaScript (106)
JSP (66)
Oracle (114)
Perl (46)
Perl (1)
PHP (1)
PL/SQL (1)
RSS (51)
Software QA (13)
SQL Server (1)
Windows (1)
XHTML (173)
Other Resources:
Why Does Poeple Import org.junit.Assert Statically
Why Does Poeple Import org.junit.Assert Statically?
✍: Guest
Poeple use the static import statement on org.junit.Assert to save coding time on calling its assetion methods. With a normal import statement, assertion method names must qualified with the class name like this:
import org.junit.Assert;
...
Assert.assertEquals(12, message.length());
With a static import statement, assertion method names can be used directly like this:
import static org.junit.Assert.*;
...
assertEquals(12, message.length());
2008-01-29, 5697👍, 0💬
Popular Posts:
How do you handle change request? Normally change request are handled by preparing an Impact analysi...
What Articles Have You Read about JUnit? There are a number of JUnit articles that you should read: ...
What are secure and non-secure websites? A secure Website uses the Secure Socket Layer (SSL) protoco...
How do we enable SQL Cache Dependency in ASP.NET 2.0? Below are the broader steps to enable a SQL Ca...
How To Enter Boolean Values in SQL Statements? - MySQL FAQs - Introduction to SQL Basics If you want...