Package org.ethereum.vm

Examples of org.ethereum.vm.Program


    @Test // CALLDATALOAD OP
    public void testCALLDATALOAD_4() {

        VM vm = new VM();
        program =
                new Program(Hex.decode("602335"), invoke);
        String s_expected_1 = "00000000000000000000000000000000000000000000000000000000B1000000";

        vm.step(program);
        vm.step(program);
View Full Code Here


    @Test // CALLDATALOAD OP
    public void testCALLDATALOAD_5() {

        VM vm = new VM();
        program =
                new Program(Hex.decode("603F35"), invoke);
        String s_expected_1 = "B100000000000000000000000000000000000000000000000000000000000000";

        vm.step(program);
        vm.step(program);
View Full Code Here

    @Test(expected=RuntimeException.class) // CALLDATALOAD OP mal
    public void testCALLDATALOAD_6() {

        VM vm = new VM();
        program =
                new Program(Hex.decode("35"), invoke);
        try {
            vm.step(program);
        } finally {
            assertTrue(program.isStopped());
        }
View Full Code Here

    @Test // CALLDATACOPY OP
    public void testCALLDATACOPY_1() {

        VM vm = new VM();
        program =
                new Program(Hex.decode("60206000600037"), invoke);
        String m_expected = "00000000000000000000000000000000000000000000000000000000000000A1";

        vm.step(program);
        vm.step(program);
        vm.step(program);
View Full Code Here

    @Test // CALLDATACOPY OP
    public void testCALLDATACOPY_2() {

        VM vm = new VM();
        program =
                new Program(Hex.decode("60406000600037"), invoke);
        String m_expected = "00000000000000000000000000000000000000000000000000000000000000A1" +
                            "00000000000000000000000000000000000000000000000000000000000000B1";

        vm.step(program);
        vm.step(program);
View Full Code Here

    @Test // CALLDATACOPY OP
    public void testCALLDATACOPY_3() {

        VM vm = new VM();
        program =
                new Program(Hex.decode("60406004600037"), invoke);
        String m_expected = "000000000000000000000000000000000000000000000000000000A100000000" +
                            "000000000000000000000000000000000000000000000000000000B100000000";

        vm.step(program);
        vm.step(program);
View Full Code Here

    @Test // CALLDATACOPY OP
    public void testCALLDATACOPY_4() {

        VM vm = new VM();
        program =
                new Program(Hex.decode("60406000600437"), invoke);
        String m_expected = "0000000000000000000000000000000000000000000000000000000000000000" +
                            "000000A100000000000000000000000000000000000000000000000000000000" +
                            "000000B100000000000000000000000000000000000000000000000000000000";

        vm.step(program);
View Full Code Here

    @Test // CALLDATACOPY OP
    public void testCALLDATACOPY_5() {

        VM vm = new VM();
        program =
                new Program(Hex.decode("60406000600437"), invoke);
        String m_expected = "0000000000000000000000000000000000000000000000000000000000000000" +
                            "000000A100000000000000000000000000000000000000000000000000000000" +
                            "000000B100000000000000000000000000000000000000000000000000000000";

        vm.step(program);
View Full Code Here

    @Test(expected=StackTooSmallException.class) // CALLDATACOPY OP mal
    public void testCALLDATACOPY_6() {

        VM vm = new VM();
        program =
                new Program(Hex.decode("6040600037"), invoke);

        try {
            vm.step(program);
            vm.step(program);
            vm.step(program);
View Full Code Here

    @Test(expected=OutOfGasException.class) // CALLDATACOPY OP mal
    public void testCALLDATACOPY_7() {

        VM vm = new VM();
        program =
                new Program(Hex.decode("6020600073CC0929EB16730E7C14FEFC63006AC2D794C5795637"), invoke);

        try {
            vm.step(program);
            vm.step(program);
            vm.step(program);
View Full Code Here

TOP

Related Classes of org.ethereum.vm.Program

Copyright © 2018 www.massapicom. 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.