Add test for FreenetRequest
[Sone.git] / src / test / java / net / pterodactylus / sone / data / ProfileTest.java
1 package net.pterodactylus.sone.data;
2
3 import net.pterodactylus.sone.data.Profile.Field;
4
5 import org.hamcrest.MatcherAssert;
6 import org.hamcrest.Matchers;
7 import org.junit.Test;
8 import org.mockito.Mockito;
9
10 /**
11  * Unit test for {@link Profile}.
12  *
13  * @author <a href="mailto:bombe@pterodactylus.net">David ‘Bombe’ Roden</a>
14  */
15 public class ProfileTest {
16
17         private final Sone sone = Mockito.mock(Sone.class);
18         private final Profile profile = new Profile(sone);
19
20         @Test
21         public void newFieldsAreInitializedWithAnEmptyString() {
22                 Field newField = profile.addField("testField");
23                 MatcherAssert.assertThat(newField.getValue(), Matchers.is(""));
24         }
25
26 }