Skip to content

Commit

Permalink
test: fix incorrect usage in theming tests (#25259)
Browse files Browse the repository at this point in the history
When we switched to the `@use` API we did not update some of the tests.
#22173

(cherry picked from commit c28bbde)
  • Loading branch information
devversion committed Jul 12, 2022
1 parent 53fb843 commit beffbfc
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 14 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ $mat-theme-ignore-duplication-warnings: true;

$theme: mat-light-theme((
color: (
primary: $mat-red,
accent: $mat-blue,
primary: mat-define-palette($mat-red),
accent: mat-define-palette($mat-blue),
),
density: -2,
));
Expand Down
24 changes: 12 additions & 12 deletions src/material/core/theming/tests/theming-api.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,8 @@ describe('theming api', () => {
transpile(`
$theme: mat-light-theme((
color: (
primary: $mat-red,
accent: $mat-red,
primary: mat-define-palette($mat-red),
accent: mat-define-palette($mat-red),
)
));
Expand All @@ -57,14 +57,14 @@ describe('theming api', () => {
transpile(`
$theme: mat-light-theme((
color: (
primary: $mat-red,
accent: $mat-red,
primary: mat-define-palette($mat-red),
accent: mat-define-palette($mat-red),
)
));
$theme2: mat-light-theme((
color: (
primary: $mat-red,
accent: $mat-blue,
primary: mat-define-palette($mat-red),
accent: mat-define-palette($mat-blue),
)
));
Expand Down Expand Up @@ -248,14 +248,14 @@ describe('theming api', () => {
it('should be possible to specify palettes by keyword', () => {
transpile(`
$light-theme: mat-light-theme(
$primary: $mat-red,
$accent: $mat-blue,
$warn: $mat-red,
$primary: mat-define-palette($mat-red),
$accent: mat-define-palette($mat-blue),
$warn: mat-define-palette($mat-red),
);
$dark-theme: mat-dark-theme(
$primary: $mat-red,
$accent: $mat-blue,
$warn: $mat-red,
$primary: mat-define-palette($mat-red),
$accent: mat-define-palette($mat-blue),
$warn: mat-define-palette($mat-red),
);
`);
});
Expand Down

0 comments on commit beffbfc

Please sign in to comment.