Box extends Dimension { boolean fitRotate3DSmallestFootprint(Dimension space) { return fitRotate3DSmallestFootprint(space.getWidth(), space.getDepth(), space.getHeight()); } Box(int w, int d, int h, int weight);  Box(String name, int w, int d, int h, int weight);  Box(final Dimension dimension, final Integer weight); Box rotate3D(); Box clone(); Box rotate2D(); Box rotate2D3D(); int getWeight(); @Override String toString();  }
@Test void testSmallestFootprintMinimum() { Box box = new Box(1, 1, 10, 0); Assert.assertTrue(box.fitRotate3DSmallestFootprint(1, 1, 10)); assertThat(box.getWidth(), is(1)); assertThat(box.getDepth(), is(1)); assertThat(box.getHeight(), is(10)); Assert.assertTrue(box.fitRotate3DSmallestFootprint(10, 1, 1)); assertThat(box.getWidth(), is(10)); assertThat(box.getDepth(), is(1)); assertThat(box.getHeight(), is(1)); Assert.assertTrue(box.fitRotate3DSmallestFootprint(1, 10, 1)); assertThat(box.getWidth(), is(1)); assertThat(box.getDepth(), is(10)); assertThat(box.getHeight(), is(1)); }