feat: Added file formatting

This commit is contained in:
2025-06-11 11:56:39 +02:00
parent 772fc52cf6
commit a25a90c0d7
164 changed files with 4163 additions and 3242 deletions

View File

@@ -1,52 +1,52 @@
import { ComponentFixture, TestBed } from '@angular/core/testing';
import { ComponentFixture, TestBed } from '@angular/core/testing'
import { GradesComponent } from './grades.component';
import { AdminCommService } from '../admin-comm.service';
import { RouterModule } from '@angular/router';
import { Component, EventEmitter, Input, Output } from '@angular/core';
import { MatIconModule } from '@angular/material/icon';
import { MatFormFieldModule } from '@angular/material/form-field';
import { of } from 'rxjs';
import { FormsModule, ReactiveFormsModule } from '@angular/forms';
import { MatInputModule } from '@angular/material/input';
import { NoopAnimationsModule } from '@angular/platform-browser/animations';
import { DateTime } from 'luxon';
import { GradesComponent } from './grades.component'
import { AdminCommService } from '../admin-comm.service'
import { RouterModule } from '@angular/router'
import { Component, EventEmitter, Input, Output } from '@angular/core'
import { MatIconModule } from '@angular/material/icon'
import { MatFormFieldModule } from '@angular/material/form-field'
import { of } from 'rxjs'
import { FormsModule, ReactiveFormsModule } from '@angular/forms'
import { MatInputModule } from '@angular/material/input'
import { NoopAnimationsModule } from '@angular/platform-browser/animations'
import { DateTime } from 'luxon'
@Component({
selector: "app-date-selector", template: '',
standalone: false
selector: 'app-date-selector',
template: '',
standalone: false,
})
class DateSelectorStub {
@Input() date: string = DateTime.now().toISODate();
@Output() dateChange = new EventEmitter<string>();
@Input() filter: (date: DateTime | null) => boolean = () => true
@Input() date: string = DateTime.now().toISODate()
@Output() dateChange = new EventEmitter<string>()
@Input() filter: (date: DateTime | null) => boolean = () => true
}
@Component({
selector: "app-room-chooser", template: '',
standalone: false
selector: 'app-room-chooser',
template: '',
standalone: false,
})
class RoomSelectorStub {
@Input() rooms: string[] = []
@Output() room: EventEmitter<string> = new EventEmitter<string>();
@Output() room: EventEmitter<string> = new EventEmitter<string>()
}
describe('GradesComponent', () => {
let component: GradesComponent;
let fixture: ComponentFixture<GradesComponent>;
let component: GradesComponent
let fixture: ComponentFixture<GradesComponent>
let acMock
beforeEach(async () => {
acMock = {
clean: {
getConfig: jasmine.createSpy("getConfig").and.returnValue(of())
}
getConfig: jasmine.createSpy('getConfig').and.returnValue(of()),
},
}
await TestBed.configureTestingModule({
declarations: [GradesComponent, DateSelectorStub, RoomSelectorStub],
providers: [
{provide: AdminCommService, useValue: acMock}
],
providers: [{ provide: AdminCommService, useValue: acMock }],
imports: [
RouterModule.forRoot([]),
MatIconModule,
@@ -54,17 +54,16 @@ describe('GradesComponent', () => {
FormsModule,
ReactiveFormsModule,
MatInputModule,
NoopAnimationsModule
]
})
.compileComponents();
fixture = TestBed.createComponent(GradesComponent);
component = fixture.componentInstance;
fixture.detectChanges();
});
NoopAnimationsModule,
],
}).compileComponents()
fixture = TestBed.createComponent(GradesComponent)
component = fixture.componentInstance
fixture.detectChanges()
})
it('should create', () => {
expect(component).toBeTruthy();
});
});
expect(component).toBeTruthy()
})
})