Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Alex angular 19 migration #6712

Merged
merged 21 commits into from
Dec 10, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
fix(workflow): fixing tests
  • Loading branch information
lexasq committed Dec 10, 2024
commit b7e4a50443bd4f2070144b1baa7054e8d5df5920
3 changes: 2 additions & 1 deletion src/accordion/testing/accordion.component.spec.ts
Original file line number Diff line number Diff line change
@@ -5,7 +5,8 @@ import { AccordionConfig, AccordionModule } from '../index';

@Component({
selector: 'accordion-test',
template: ''
template: '',
standalone: false
})
class TestAccordionComponent {
oneAtATime = true;
1 change: 1 addition & 0 deletions src/datepicker/testing/bs-datepicker-day-decorator.spec.ts
Original file line number Diff line number Diff line change
@@ -10,6 +10,7 @@ import '../../../scripts/jest/toHaveCssClass';
@Component({
selector: 'test-cmp',
template: `<span bsDatepickerDayDecorator [day]='day'>{{ day.label }}</span>`,
standalone: false
})
class TestComponent {
day: DayViewModel = { date: new Date(), label: '' };
Original file line number Diff line number Diff line change
@@ -11,6 +11,7 @@ import { BsDatepickerNavigationViewComponent } from '../themes/bs/bs-datepicker-
[calendar]="month"
(onNavigate)="navTo($event)"
></bs-datepicker-navigation-view>`,
standalone: false
})
class TestComponent {
month!: DaysCalendarViewModel;
1 change: 1 addition & 0 deletions src/datepicker/testing/bs-datepicker.spec.ts
Original file line number Diff line number Diff line change
@@ -15,6 +15,7 @@ import { BsDatepickerContainerComponent } from '../themes/bs/bs-datepicker-conta
template: `<input type='text'
bsDatepicker
[bsConfig]='bsConfig'>`,
standalone: false
})
class TestComponent {
@ViewChild(BsDatepickerDirective, { static: false }) datepicker: BsDatepickerDirective;
1 change: 1 addition & 0 deletions src/datepicker/testing/bs-daterangepicker.spec.ts
Original file line number Diff line number Diff line change
@@ -14,6 +14,7 @@ import { firstValueFrom } from 'rxjs';
template: `<input type="text"
bsDaterangepicker
[bsConfig]="bsConfig">`,
standalone: false
})
class TestComponent {
@ViewChild(BsDaterangepickerDirective, { static: false }) daterangepicker: BsDaterangepickerDirective;
3 changes: 2 additions & 1 deletion src/datepicker/testing/bs-inline-datepicker.spec.ts
Original file line number Diff line number Diff line change
@@ -13,7 +13,8 @@ import { getYearsCalendarInitialDate } from '../utils/bs-calendar-utils';

@Component({
selector: 'test-cmp',
template: `<bs-datepicker-inline [bsConfig]="bsConfig"></bs-datepicker-inline>>`
template: `<bs-datepicker-inline [bsConfig]="bsConfig"></bs-datepicker-inline>>`,
standalone: false
})
class TestComponent {
@ViewChild(BsDatepickerInlineDirective, { static: false }) datepicker: BsDatepickerInlineDirective;
3 changes: 2 additions & 1 deletion src/datepicker/testing/bs-inline-daterangepicker.spec.ts
Original file line number Diff line number Diff line change
@@ -13,7 +13,8 @@ import { initialYearShift } from '../engine/format-years-calendar';
@Component({
selector: 'test-cmp',
template: `
<bs-daterangepicker-inline [bsConfig]="bsConfig"></bs-daterangepicker-inline>`
<bs-daterangepicker-inline [bsConfig]="bsConfig"></bs-daterangepicker-inline>`,
standalone: false
})
class TestComponent {
@ViewChild(BsDaterangepickerInlineDirective, { static: false }) datepicker: BsDaterangepickerInlineDirective;
3 changes: 2 additions & 1 deletion src/dropdown/testing/bs-dropdown.directive.spec.ts
Original file line number Diff line number Diff line change
@@ -7,7 +7,8 @@ import { BsDropdownConfig, BsDropdownDirective, BsDropdownModule } from '../inde

@Component({
selector: 'dropdown-test',
template: ''
template: '',
standalone: false
})
class TestDropdownComponent {
isOpen = false;
5 changes: 3 additions & 2 deletions src/modal/testing/modal.default-setting.spec.ts
Original file line number Diff line number Diff line change
@@ -4,14 +4,15 @@ import { TestBed, ComponentFixture } from '@angular/core/testing';
import { BsModalService, ModalModule } from '../index';
import { MODAL_CONFIG_DEFAULT_OVERRIDE } from '../modal-options.class';

@Component({ template: '<div>Dummy Component</div>' })
@Component({ template: '<div>Dummy Component</div>', standalone: false })
class DummyComponent {
// eslint-disable-next-line @typescript-eslint/no-empty-function,@typescript-eslint/no-unused-vars
constructor(modalService: BsModalService) {}
}

@Component({
template: '<div>Test Component</div>'
template: '<div>Test Component</div>',
standalone: false
})
class TestModalComponent {}

5 changes: 3 additions & 2 deletions src/modal/testing/modal.service.spec.ts
Original file line number Diff line number Diff line change
@@ -4,14 +4,15 @@ import { pairwise, tap } from 'rxjs/operators';

import { BsModalService, ModalModule } from '../index';

@Component({ template: '<div>Dummy Component</div>' })
@Component({ template: '<div>Dummy Component</div>', standalone: false })
class DummyComponent {
// eslint-disable-next-line @typescript-eslint/no-empty-function,@typescript-eslint/no-unused-vars
constructor(modalService: BsModalService) { }
}

@Component({
template: '<div>Test Component</div>'
template: '<div>Test Component</div>',
standalone: false
})
export class TestModalComponent { }

3 changes: 2 additions & 1 deletion src/positioning/testing/computeAutoPlacement.spec.ts
Original file line number Diff line number Diff line change
@@ -6,7 +6,8 @@ import { Offsets } from '../models';

@Component({
selector: 'test-cmp',
template: `<span>Popover demo</span>`
template: `<span>Popover demo</span>`,
standalone: false
})
class TestComponent {}

3 changes: 2 additions & 1 deletion src/positioning/testing/getBoundingClientRect.spec.ts
Original file line number Diff line number Diff line change
@@ -4,7 +4,8 @@ import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';

@Component({
selector: 'test-cmp',
template: `<span>Popover demo</span>`
template: `<span>Popover demo</span>`,
standalone: false
})
class TestComponent {}

3 changes: 2 additions & 1 deletion src/progressbar/testing/progressbar.component.spec.ts
Original file line number Diff line number Diff line change
@@ -4,7 +4,8 @@ import { ProgressbarComponent, ProgressbarModule } from '../index';

@Component({
selector: 'progressbar-test',
template: ''
template: '',
standalone: false
})
class TestProgressbarComponent extends ProgressbarComponent {}

3 changes: 2 additions & 1 deletion src/rating/testing/rating.component.spec.ts
Original file line number Diff line number Diff line change
@@ -6,7 +6,8 @@ import { RatingComponent, RatingConfig, RatingModule } from '../index';

@Component({
selector: 'rating-test',
template: ''
template: '',
standalone: false
})
class TestRatingComponent {
max = 5;
3 changes: 2 additions & 1 deletion src/tabs/testing/tabset.component.spec.ts
Original file line number Diff line number Diff line change
@@ -4,7 +4,8 @@ import { TabsetConfig, TabsModule, TabsetComponent } from '../index';

@Component({
selector: 'tabs-test',
template: ''
template: '',
standalone: false
})
class TestTabsetComponent {
isVertical = false;
3 changes: 2 additions & 1 deletion src/tooltip/testing/tooltip.directive.spec.ts
Original file line number Diff line number Diff line change
@@ -6,7 +6,8 @@ import { TooltipModule } from '../index';

@Component({
selector: 'test-tooltip',
template: ''
template: '',
standalone: false
})
class TestTooltipComponent {
delay = 0;
3 changes: 2 additions & 1 deletion src/typeahead/testing/typeahead.directive.spec.ts
Original file line number Diff line number Diff line change
@@ -22,7 +22,8 @@ interface State {
[typeaheadOptionField]="'name'"
[adaptivePosition]="false"
(typeaheadOnBlur)="onBlurEvent($event)"
/>`
/>`,
standalone: false
})
class TestTypeaheadComponent {
selectedState?: string;