* Initializes the constructs with which all test cases are authored.
()
| 74 | * Initializes the constructs with which all test cases are authored. |
| 75 | */ |
| 76 | function initializeTestConstructs() { |
| 77 | // Allow Mocha's it() to call yield and allow pending promises to resolve. |
| 78 | installYieldIt(it); |
| 79 | |
| 80 | // Make Mocha's describe() and it() globally configurable. |
| 81 | describe.configure = () => new TestConfig(describe); |
| 82 | it.configure = () => new TestConfig(it); |
| 83 | |
| 84 | // Make AMP's custom describes() globally available. |
| 85 | global.describes = describes; |
| 86 | |
| 87 | // Set up Mocha's global setup / clean up functions. |
| 88 | before(overrideSkipTest); |
| 89 | beforeEach(setupTestcase); |
| 90 | afterEach(cleanupTestcase); |
| 91 | } |
| 92 | |
| 93 | /** |
| 94 | * Overrides AMP.extension() so that extension installation is buffered and |
no test coverage detected