message: Added additional test coverage for CommandNode
diff: @@ -19,6 +19,34 @@ import Command from "../../../models/Command";
  import { CommandNode } from "../../../playback/playback-tree/command-node";
  describe("Command Node", () => {
  + it("control flow check returns correct result", () => {
  + let command = new Command(undefined, "if", "", "");
  + let node = new CommandNode(command);
  + expect(node.isControlFlow()).toBeTruthy();
  + command = new Command(undefined, "command", "", "");
  + node = new CommandNode(command);
  + node.left = "asdf";
  + expect(node.isControlFlow()).toBeTruthy();
  + command = new Command(undefined, "command", "", "");
  + node = new CommandNode(command);
  + node.right = "asdf";
  + expect(node.isControlFlow()).toBeTruthy();
  + });
  + it("retry limit defaults to 1000", () => {
  + const command = new Command(undefined, "command", "", "");
  + const node = new CommandNode(command);
  + node.timesVisited = 999;
  + expect(node._isRetryLimit()).toBeFalsy();
  + node.timesVisited = 1000;
  + expect(node._isRetryLimit()).toBeTruthy();
  + });
  +
  + it("retry limit can be overriden", () => {
  + const command = new Command(undefined, "command", "", 5);
  + const node = new CommandNode(command);
  + node.timesVisited = 5;
  + expect(node._isRetryLimit()).toBeTruthy();
  + });
  it("resolves with an error message when too many retries attempted in a loop", () => {
  const command = new Command(undefined, "command", "", 2);
  const node = new CommandNode(command);
  @@ -27,12 +55,12 @@ describe("Command Node", () => {
  expect(result.result).toEqual("Max retry limit exceeded. To override it, specify a new limit in the value input field.");
  });
  });
  -
  - it("resolves with an error message on times when an invalid number is provided", () => {
  + it("resolves with an error message on 'times' when an invalid number is provided", () => {
  const command = new Command(undefined, "times", "asdf", "");
  const node = new CommandNode(command);
  node._evaluate().then((result) => {
  expect(result.result).toEqual("Invalid number provided as a target.");
  });
  });
  +
  });
  