anchor.diff:  :marked
     # Introduction to the Angular Testing Utilities
   
  +  # Angular测试工具入门
  +
     Many tests explore how applications classes interact with Angular and the DOM while under Angular's control.
   
     许多测试探索应用的类在被`Angular`控制时，是如何与`Angular`和`DOM`互动的。
  
positive.code:   <a href="https://developer.mozilla.org/en-US/docs/Web/Guide/CSS/Getting_started/Selectors" target="_blank">standard CSS selector</a>
    predicate that filters the same way as a jQuery selector.
  
    Finally, the setup assigns the DOM element from the `DebugElement` **`nativeElement`** property to `el`.
    The tests will assert that `el` contains the expected title text.
  
  
    ### The tests
    Jasmine runs the `beforeEach` function before each of these tests
  +makeExample('testing/ts/app/banner.component.spec.ts', 'tests', 'app/banner.component.spec.ts (tests)')(format='.')
  :marked
    These tests ask the `DebugElement` for the native HTML element to satisfy their expectations.
  
negative.code:   The base state includes a default testing module configuration consisting of the
    declarables (components, directives, and pipes) and providers (some of them mocked)
    that almost everyone needs.
  
    在每个测试之前，`TestBed`将自己重设为初始状态。
    这个初始状态包含了一个默认的、几乎所有情况都需要的测试模块配置，包括可声明类（组件、指令和管道）和提供商（其中一些是伪造的）。
  
  .l-sub-section
    :marked
      The testing shims mentioned [earlier](#setup) initialize the testing module configuration
      to something like the `BrowserModule` from `@angular/platform-browser`.
  
      [之前](#setup)提到的测试垫片初始化测试模块配置到一个模块，这个模块和`@angular/platform-browser`中的`BrowserModule`类似。
  :marked
    This default configuration is merely a _foundation_ for testing an app.
    You call `TestBed.configureTestingModule` with an object that defines additional imports, declarations, providers and schemas
    to fit your application tests.
    Optional `override...` methods can fine-tune aspects of the configuration.
  
    默认配置只是测试一个应用的**基础**。
    使用一个定义额外inports、declarations、providers和schemas的对象来调用`TestBed.configureTestingModule`，以适合你的应用程序的测试。
    可选的`override...`方法可以微调配置的各个方面。
  
    After configuring the `TestBed`, tell it to create an instance of the _component-under-test_ and the test fixture
    that you'll need to inspect and control the component's immediate environment.
  
    `TestBed`配置完成以后，用它创建一个**被测试的组件**的实例和测试fixture，用来检查和控制组件周围的环境。
    
  +makeExample('testing/ts/app/banner.component.spec.ts', 'simple-example-before-each', 'app/banner.component.spec.ts (simplified)')(format='.')
  :marked
  