Package fitnesse.slim.instructions

Examples of fitnesse.slim.instructions.CallInstruction


                    "\n" +
                    "!|localisedScript|\n" +
                    "|myScenario|7|\n"
    );
    List<CallInstruction> expectedInstructions =
            asList(new CallInstruction("localizedScriptTable_id_0/localizedScriptTable_s_id_0", "localizedScriptTableActor", "function", new Object[]{"7"}));
    assertEquals(expectedInstructions, instructions());
  }
View Full Code Here


        "\n" +
        "!|script|\n" +
        "|f|1||2|\n"
    );
    List<CallInstruction> expectedInstructions =
            asList(new CallInstruction("scriptTable_id_0/scriptTable_s_id_0", "scriptTableActor", "function", new Object[]{"1", "2"}));
    assertEquals(expectedInstructions, instructions());
  }
View Full Code Here

        "!|script|\n" +
        "|login|bob|password|xyzzy|pin|7734|\n" +
        "|login|bill|password|yabba|pin|8892|\n"
    );
    List<CallInstruction> expectedInstructions =
            asList(new CallInstruction("scriptTable_id_0/scriptTable_s_id_0", "scriptTableActor", "loginWithPasswordAndPin", new Object[]{"bob", "xyzzy", "7734"}), new CallInstruction("scriptTable_id_1/scriptTable_s_id_0", "scriptTableActor", "loginWithPasswordAndPin", new Object[]{"bill", "yabba", "8892"}));
    assertEquals(expectedInstructions, instructions());
  }
View Full Code Here

        "\n" +
        "!|script|\n" +
        "|Login user Bob with password xyzzy|\n"
    );
    List<CallInstruction> expectedInstructions =
            asList(new CallInstruction("scriptTable_id_0/scriptTable_s_id_0", "scriptTableActor", "loginWith", new Object[]{"Bob", "xyzzy"}));
    assertEquals(expectedInstructions, instructions());
  }
View Full Code Here

        "\n" +
        "!|script|\n" +
        "|Login user Bob with password xyzzy|\n"
    );
    List<CallInstruction> expectedInstructions =
            asList(new CallInstruction("scriptTable_id_0/scriptTable_s_id_0", "scriptTableActor", "loginWith", new Object[]{"Bob", "xyzzy"}));
    assertEquals(expectedInstructions, instructions());
  }
View Full Code Here

    script = new ScriptTable(ts.getTable(2), "id", testContext);
    assertions.addAll(st1.getAssertions());
    assertions.addAll(st2.getAssertions());
    assertions.addAll(script.getAssertions());
    List<CallInstruction> expectedInstructions =
            asList(new CallInstruction("scriptTable_id_0/scriptTable_s2_id_0", "scriptTableActor", "loginWith", new Object[]{"Bob", "xyzzy"}));
    assertEquals(expectedInstructions, instructions());
  }
View Full Code Here

    script = new ScriptTable(ts.getTable(2), "id", testContext);
    assertions.addAll(st1.getAssertions());
    assertions.addAll(st2.getAssertions());
    assertions.addAll(script.getAssertions());
    List<CallInstruction> expectedInstructions =
            asList(new CallInstruction("scriptTable_id_0/scriptTable_s2_id_0", "scriptTableActor", "loginWithUsernameAndPassword", new Object[]{"Bob", "xyzzy"}));
    assertEquals(expectedInstructions, instructions());
  }
View Full Code Here

    script = new ScriptTable(ts.getTable(2), "id", testContext);
    assertions.addAll(st1.getAssertions());
    assertions.addAll(st2.getAssertions());
    assertions.addAll(script.getAssertions());
    List<CallInstruction> expectedInstructions =
            asList(new CallInstruction("scriptTable_id_0/scriptTable_s2_id_0", "scriptTableActor", "loginWithUsernameAndPassword", new Object[]{"Bob", "xyzzy"}));
    assertEquals(expectedInstructions, instructions());
  }
View Full Code Here

    private List<SlimAssertion> callSetForVariables(int row) {
      List<SlimAssertion> assertions = new ArrayList<SlimAssertion>();
      for (String var : varStore.getLeftToRightAndResetColumnNumberIterator()) {
        int col = varStore.getColumnNumber(var);
        String valueToSet = table.getCellContents(col, row);
        Instruction setInstruction = new CallInstruction(makeInstructionTag(), getTableName(), "set", new Object[] {var, valueToSet});
        assertions.add(makeAssertion(setInstruction, new VoidReturnExpectation(col, row)));
      }
      return assertions;
    }
View Full Code Here

    }
    return arguments.toArray(new String[arguments.size()]);
  }

  protected Instruction callFunction(String instanceName, String functionName, Object... args) {
    return new CallInstruction(makeInstructionTag(), instanceName, Disgracer.disgraceMethodName(functionName), args);
  }
View Full Code Here

TOP

Related Classes of fitnesse.slim.instructions.CallInstruction

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.