1 2package com.badlogic.gdx.math; 3 4import static org.junit.Assert.*; 5 6import org.junit.Test; 7 8public class RectangleTest { 9 @Test 10 public void testToString () { 11 assertEquals("[5.0,-4.1,0.03,-0.02]", new Rectangle(5f, -4.1f, 0.03f, -0.02f).toString()); 12 } 13 14 @Test 15 public void testFromString () { 16 assertEquals(new Rectangle(5f, -4.1f, 0.03f, -0.02f), new Rectangle().fromString("[5.0,-4.1,0.03,-0.02]")); 17 } 18} 19