angular/aio/content/examples/testing/src/app/welcome
shejialuo 6e0481572f docs(docs-infra): change the testing guide due to deprecation (#44674)
The jasmine used in the docs is

```typescript
expect(<variableName>).<matcher>(predicate, failOutput)
```

The new version should be

```typescript
expect(<variableName>).withContext(failOutput).<matcher>(predicate)
```

So, this commit mainly focuses on changing the former to latter with
format below

```typescript
expect(<variableName>)
  .withContext(failOutput)
  .<matcher>(predicate)
```

And for RxJs, see https://rxjs.dev/deprecations/subscribe-arguments.

> For example someone could name functions poorly and confuse the next
reader: `source$.subscribe(doSomething, doSomethingElse, lol)` with that
signature, you have to know unapparent details about subscribe, where
using a partial observer solves that neatly: `source$.subscribe({ next:
doSomething, error: doSomethingElse, complete: lol }`).

This commit also does this conversion.

Last, remove the unused imported `async` from file
`twain.component.marbles.spec.ts`.

PR Close #44674
2022-01-13 12:46:24 -08:00
..
welcome.component.spec.ts docs(docs-infra): change the testing guide due to deprecation (#44674) 2022-01-13 12:46:24 -08:00
welcome.component.ts docs: make all examples compatible with strict mode (#41999) 2021-05-17 10:42:18 -07:00