package com.pollistics.models;

import static org.assertj.core.api.Assertions.assertThat;

import org.junit.Test;

public class SecUserDetailsTest {
	@Test
	public void membersTest() {			
		User u = new User("testuser", "testpass");
		User u2 = new User("testuser2", "testpass2");
		SecUserDetails uSec = new SecUserDetails(u);
		assertThat(uSec.getUser().equals(u));
		uSec.setUser(u2);
		assertThat(uSec.getUser().equals(u2));
		assertThat(uSec.getPassword().equals(u2.getPassword()));
		assertThat(uSec.getUsername().equals(u2.getUsername()));
		assertThat(uSec.getAuthorities() == null);
		assertThat(uSec.isAccountNonExpired() == true);
		assertThat(uSec.isAccountNonLocked() == true);
		assertThat(uSec.isCredentialsNonExpired() == true);
		assertThat(uSec.isEnabled() == true);
	}
}

@@ -25,16 +25,40 @@
 odels;%0A%0A
+import org.junit.Test;%0A%0A
 import s
@@ -112,32 +112,8 @@
 t;%0A%0A
-import org.junit.Test;%0A%0A
 publ
@@ -181,11 +181,8 @@
 () %7B
-%09%09%09
 %0A%09%09U
@@ -617,32 +617,24 @@
 NonExpired()
- == true
 );%0A%09%09assertT
@@ -658,32 +658,24 @@
 tNonLocked()
- == true
 );%0A%09%09assertT
@@ -704,32 +704,24 @@
 NonExpired()
- == true
 );%0A%09%09assertT
@@ -744,16 +744,8 @@
 ed()
- == true
 );%0A%09

simplify tests, true will mean that test passes