GeezerVisonThe World Wide Web, restored to 800 pixels of glory. |
| Home|About|Gaming cabinet|Archives|How it works|Starter sites |
GeezerVison is showing next.angular.dev — createAngularTestingModule • Angular API@paramangularJSModules string[]a collection of the names of AngularJS modules to include in the configuration. @paramstrictDi boolean | undefinedwhether the AngularJS injector should have @returns Type<any>DescriptionA helper function to use when unit testing Angular services that depend upon upgraded AngularJS services. This function returns an Use the returned class as an "import" when configuring the In the following code snippet, we are configuring the TestBed with two imports.
The
Once this is done we can get hold of services via the Angular In the following code snippet,
This helper is for testing services not Components.
For Component testing you must still bootstrap a hybrid app. See The resulting configuration does not wire up AngularJS digests to Zone hooks. It is the
responsibility of the test writer to call The helper sets up global variables to hold the shared Angular and AngularJS injectors.
Here is the example application and its unit tests that use |
| You are visitor 01402520 — GeezerVison does not store the pages you look up. Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required. |