Examples of assertCountsEqual()


Examples of libshapedraw.MockMinecraftAccess.assertCountsEqual()

            // A render cap that's larger than the number of line segments defined is fine too
            shape.setRenderCap(9001);
            mc.reset();
            shape.render(mc);
            mc.assertCountsEqual(1, 11, seeThru);
            shape.render(mc);
            shape.render(mc);
            shape.render(mc);
            mc.assertCountsEqual(4, 44, seeThru);
        }
View Full Code Here

Examples of libshapedraw.MockMinecraftAccess.assertCountsEqual()

            shape.render(mc);
            mc.assertCountsEqual(1, 11, seeThru);
            shape.render(mc);
            shape.render(mc);
            shape.render(mc);
            mc.assertCountsEqual(4, 44, seeThru);
        }
    }

    @SuppressWarnings({ "rawtypes", "unchecked" })
    @Test(expected=ClassCastException.class)
View Full Code Here

Examples of libshapedraw.event.MockLSDEventListener.assertCountsEqual()

    }

    @Test
    public void testEventListenersFire() {
        MockLSDEventListener counter = new MockLSDEventListener();
        counter.assertCountsEqual(0, 0, 0);

        // ensure listener doesn't receive events if not registered
        LSDController.getInstance().respawn(new Vector3(0,0,0), true, true);
        LSDController.getInstance().gameTick(new Vector3(0,0,0));
        LSDController.getInstance().render(new Vector3(0,0,0), false);
View Full Code Here

Examples of libshapedraw.event.MockLSDEventListener.assertCountsEqual()

        // ensure listener doesn't receive events if not registered
        LSDController.getInstance().respawn(new Vector3(0,0,0), true, true);
        LSDController.getInstance().gameTick(new Vector3(0,0,0));
        LSDController.getInstance().render(new Vector3(0,0,0), false);
        counter.assertCountsEqual(0, 0, 0);

        // register listener and ensure events are received
        lib.addEventListener(counter);

        LSDController.getInstance().respawn(new Vector3(0,0,0), true, true);
View Full Code Here

Examples of libshapedraw.event.MockLSDEventListener.assertCountsEqual()

        // register listener and ensure events are received
        lib.addEventListener(counter);

        LSDController.getInstance().respawn(new Vector3(0,0,0), true, true);
        counter.assertCountsEqual(1, 0, 0);
        LSDController.getInstance().gameTick(new Vector3(0,0,0));
        counter.assertCountsEqual(1, 1, 0);
        LSDController.getInstance().render(new Vector3(0,0,0), false);
        counter.assertCountsEqual(1, 1, 1);
    }
View Full Code Here

Examples of libshapedraw.event.MockLSDEventListener.assertCountsEqual()

        lib.addEventListener(counter);

        LSDController.getInstance().respawn(new Vector3(0,0,0), true, true);
        counter.assertCountsEqual(1, 0, 0);
        LSDController.getInstance().gameTick(new Vector3(0,0,0));
        counter.assertCountsEqual(1, 1, 0);
        LSDController.getInstance().render(new Vector3(0,0,0), false);
        counter.assertCountsEqual(1, 1, 1);
    }

    @Test
View Full Code Here

Examples of libshapedraw.event.MockLSDEventListener.assertCountsEqual()

        LSDController.getInstance().respawn(new Vector3(0,0,0), true, true);
        counter.assertCountsEqual(1, 0, 0);
        LSDController.getInstance().gameTick(new Vector3(0,0,0));
        counter.assertCountsEqual(1, 1, 0);
        LSDController.getInstance().render(new Vector3(0,0,0), false);
        counter.assertCountsEqual(1, 1, 1);
    }

    @Test
    public void testEventListenersFireMultiple() {
        MockLSDEventListener counter0 = new MockLSDEventListener();
View Full Code Here

Examples of libshapedraw.event.MockLSDEventListener.assertCountsEqual()

        MockLSDEventListener counter2 = new MockLSDEventListener();
        lib.addEventListener(counter0).addEventListener(counter1).addEventListener(counter2);
        LSDController.getInstance().respawn(new Vector3(0,0,0), true, true);
        counter0.assertCountsEqual(1, 0, 0);
        counter1.assertCountsEqual(1, 0, 0);
        counter2.assertCountsEqual(1, 0, 0);
        LSDController.getInstance().gameTick(new Vector3(0,0,0));
        counter0.assertCountsEqual(1, 1, 0);
        counter1.assertCountsEqual(1, 1, 0);
        counter2.assertCountsEqual(1, 1, 0);
        LSDController.getInstance().render(new Vector3(0,0,0), false);
View Full Code Here

Examples of libshapedraw.event.MockLSDEventListener.assertCountsEqual()

        counter1.assertCountsEqual(1, 0, 0);
        counter2.assertCountsEqual(1, 0, 0);
        LSDController.getInstance().gameTick(new Vector3(0,0,0));
        counter0.assertCountsEqual(1, 1, 0);
        counter1.assertCountsEqual(1, 1, 0);
        counter2.assertCountsEqual(1, 1, 0);
        LSDController.getInstance().render(new Vector3(0,0,0), false);
        counter0.assertCountsEqual(1, 1, 1);
        counter1.assertCountsEqual(1, 1, 1);
        counter2.assertCountsEqual(1, 1, 1);
    }
View Full Code Here

Examples of libshapedraw.event.MockLSDEventListener.assertCountsEqual()

        counter1.assertCountsEqual(1, 1, 0);
        counter2.assertCountsEqual(1, 1, 0);
        LSDController.getInstance().render(new Vector3(0,0,0), false);
        counter0.assertCountsEqual(1, 1, 1);
        counter1.assertCountsEqual(1, 1, 1);
        counter2.assertCountsEqual(1, 1, 1);
    }

    // ----------------------------------------------------------------------
    // Other properties
    // ----------------------------------------------------------------------
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.