File tree 1 file changed +2
-13
lines changed
fxgl-entity/src/test/kotlin/com/almasb/fxgl/entity
1 file changed +2
-13
lines changed Original file line number Diff line number Diff line change @@ -48,7 +48,7 @@ class EntityTest {
48
48
}
49
49
50
50
@Test
51
- fun `Add component fails if same type already exists` () {
51
+ fun `Add component is ignored if same type already exists` () {
52
52
val exception = assertDoesNotThrow {
53
53
entity.addComponent(TestComponent ())
54
54
entity.addComponent(TestComponent ())
@@ -170,17 +170,6 @@ class EntityTest {
170
170
assertThat(entity.components, hasItem(control))
171
171
}
172
172
173
- // Test seems duplicate, see l.51 `Add component fails if same type already exists`
174
- @Test
175
- fun `Add control fails if same type exists` () {
176
- val control = TestControl ()
177
- entity.addComponent(control)
178
-
179
- assertDoesNotThrow {
180
- entity.addComponent(control)
181
- }
182
- }
183
-
184
173
@Test
185
174
fun `Add control fails if required module is missing` () {
186
175
assertThrows(IllegalStateException ::class .java, {
@@ -1028,4 +1017,4 @@ class EntityTest {
1028
1017
data = bundle.get(" data" )
1029
1018
}
1030
1019
}
1031
- }
1020
+ }
You can’t perform that action at this time.
0 commit comments