Skip to content

Commit

Permalink
fix(Outside URL): Fix tests that broke from previous commit
Browse files Browse the repository at this point in the history
  • Loading branch information
geoffreykwan committed Dec 6, 2022
1 parent 27ee21a commit c709ed1
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 3 deletions.
7 changes: 7 additions & 0 deletions src/assets/wise5/components/outsideURL/OutsideUrlContent.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
import { ComponentContent } from '../../common/ComponentContent';

export interface OutsideUrlContent extends ComponentContent {
height: number;
url: string;
width: number;
}
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,10 @@ import { MatIconModule } from '@angular/material/icon';
import { BrowserModule } from '@angular/platform-browser';
import { BrowserAnimationsModule } from '@angular/platform-browser/animations';
import { StudentTeacherCommonServicesModule } from '../../../../../app/student-teacher-common-services.module';
import { Component } from '../../../common/Component';
import { ProjectService } from '../../../services/projectService';
import { OutsideUrlStudent } from './outside-url-student.component';
import { OutsideUrlContent } from '../OutsideUrlContent';

let component: OutsideUrlStudent;
const componentId = 'component1';
Expand All @@ -35,13 +37,13 @@ describe('OutsideUrlStudentComponent', () => {
spyOn(TestBed.inject(ProjectService), 'isSpaceExists').and.returnValue(false);
spyOn(TestBed.inject(ProjectService), 'getThemeSettings').and.returnValue({});
component = fixture.componentInstance;
component.nodeId = nodeId;
component.componentContent = {
const componentContent = {
id: componentId,
height: 600,
width: 800,
url: 'https://www.berkeley.edu'
};
} as OutsideUrlContent;
component.component = new Component(componentContent, nodeId);
spyOn(component, 'subscribeToSubscriptions').and.callFake(() => {});
spyOn(component, 'broadcastDoneRenderingComponent').and.callFake(() => {});
spyOn(component, 'isAddToNotebookEnabled').and.callFake(() => {
Expand Down

0 comments on commit c709ed1

Please sign in to comment.