public class QueryParameterTest
{
@Test
public void testHashCodeAndEquals()
{
RequestParameter param1 = new QueryParameter("foo", "bar");
RequestParameter param2 = new QueryParameter("foo", "bar");
RequestParameter param3 = new QueryParameter("foo", "bar2");
RequestParameter param4 = new QueryParameter("foo2", "bar");
assertNotSame(param1.hashCode(), param3.hashCode());
assertNotSame(param1.hashCode(), param4.hashCode());
assertNotSame(param3.hashCode(), param4.hashCode());
assertEquals(param1.hashCode(), param2.hashCode());
assertNotSame(param1, param3);
assertNotSame(param1, param4);
assertNotSame(param3, param4);