- it("should contain typed json editor", async () => {
- const ele = fixture.debugElement.nativeElement.querySelector(
- "nrcp-typed-policy-editor"
- );
- expect(ele).toBeTruthy();
+ it("should contain typed json editor with empty JSON, schema and dark mode true", async () => {
+ const typedPolicyEditor: TypedPolicyEditorComponent = fixture.debugElement.query(
+ By.directive(TypedPolicyEditorComponent)
+ ).componentInstance;
+ expect(typedPolicyEditor).toBeTruthy();
+ expect(typedPolicyEditor.jsonObject).toBeFalsy();
+ expect(typedPolicyEditor.jsonSchemaObject).toEqual(typedSchema);
+ expect(typedPolicyEditor.darkMode).toBeTruthy();