Beispiel #1
0
  it("should toggle correctly through stages if initially in on/off state", () => {
    const checkbox = new TriStateCheckbox(TristateState.on);

    checkbox.click();
    expect(checkbox.isUnchecked()).toBe(true);

    checkbox.click();
    expect(checkbox.isChecked()).toBe(true);
  });
Beispiel #2
0
  it("should tell if state is changed", () => {
    const checkbox = new TriStateCheckbox(TristateState.on);

    checkbox.click();
    expect(checkbox.ischanged()).toBe(true);
  });