Commit f2d13a01 authored by Robert Knight's avatar Robert Knight

Hoist an import to the top level

In preparation for conversion to an ES module, hoist an import to the
top of the file.
parent e0020c33
...@@ -2,6 +2,7 @@ const html = require('../html'); ...@@ -2,6 +2,7 @@ const html = require('../html');
const { toResult } = require('../../../shared/test/promise-util'); const { toResult } = require('../../../shared/test/promise-util');
const fixture = require('./html-anchoring-fixture.html'); const fixture = require('./html-anchoring-fixture.html');
const htmlBaselines = require('./html-baselines');
/** Return all text node children of `container`. */ /** Return all text node children of `container`. */
function textNodes(container) { function textNodes(container) {
...@@ -419,7 +420,6 @@ describe('HTML anchoring', function() { ...@@ -419,7 +420,6 @@ describe('HTML anchoring', function() {
}); });
describe('Web page baselines', function() { describe('Web page baselines', function() {
const fixtures = require('./html-baselines');
let frame; let frame;
before(function() { before(function() {
...@@ -431,7 +431,7 @@ describe('HTML anchoring', function() { ...@@ -431,7 +431,7 @@ describe('HTML anchoring', function() {
frame.remove(); frame.remove();
}); });
fixtures.forEach(fixture => { htmlBaselines.forEach(fixture => {
it(`generates selectors which match the baseline ${fixture.name}`, () => { it(`generates selectors which match the baseline ${fixture.name}`, () => {
let fixtureHtml = fixture.html; let fixtureHtml = fixture.html;
const annotations = fixture.annotations.rows; const annotations = fixture.annotations.rows;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment