mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/CodeMirror
synced 2024-12-22 18:42:39 +00:00
24 lines
501 B
JavaScript
24 lines
501 B
JavaScript
|
'use strict';
|
||
|
|
||
|
const Api = require( 'wdio-mediawiki/Api' );
|
||
|
const Util = require( 'wdio-mediawiki/Util' );
|
||
|
|
||
|
const fixture1 = '[]{{template}}';
|
||
|
|
||
|
class FixtureContent {
|
||
|
/**
|
||
|
* Create a new fixture for testing syntax highlighting.
|
||
|
*
|
||
|
* @return {string} Page title
|
||
|
*/
|
||
|
createFixturePage() {
|
||
|
const title = Util.getTestString( 'CodeMirror-fixture1-' );
|
||
|
|
||
|
browser.call( () => Api.bot().then( ( bot ) => bot.edit( title, fixture1 ) ) );
|
||
|
|
||
|
return title;
|
||
|
}
|
||
|
}
|
||
|
|
||
|
module.exports = new FixtureContent();
|