-
Notifications
You must be signed in to change notification settings - Fork 150
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Simplify testing configuration implementation
- Loading branch information
Showing
7 changed files
with
81 additions
and
133 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
import { Injectable } from '@angular/core'; | ||
|
||
@Injectable({ | ||
providedIn: 'root', | ||
}) | ||
export class FaTestingConfig { | ||
/** | ||
* What to do when `addIcons()` or `addIconPacks()` is invoked on | ||
* the FaIconLibrary provided by the FontAwesomeTestingModule. | ||
* | ||
* Possible values are: | ||
* - `'throwError'` - Throw an error. | ||
* - `'logWarning'` - Write a warning to the console. | ||
* - `'noop'` - Do nothing. | ||
* | ||
* Note that in any case the icon will not be added to the library. | ||
* | ||
* @default 'throwError' | ||
*/ | ||
whenAddingIcons: 'throwError' | 'logWarning' | 'noop' = 'throwError'; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
export { FontAwesomeTestingModule } from './testing.module'; | ||
export { MockFaIconLibrary } from './icon/mock-icon-library.service' | ||
export { FontAwesomeTestingModuleConfig } from './TestingModuleConfig' | ||
export { MockFaIconLibrary } from './icon/mock-icon-library.service'; | ||
export { FaTestingConfig } from './config'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.