diff options
Diffstat (limited to 'tests/api-testing/REST/RevisionLegacy.js')
-rw-r--r-- | tests/api-testing/REST/RevisionLegacy.js | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/api-testing/REST/RevisionLegacy.js b/tests/api-testing/REST/RevisionLegacy.js new file mode 100644 index 000000000000..0adc7abd48b3 --- /dev/null +++ b/tests/api-testing/REST/RevisionLegacy.js @@ -0,0 +1,10 @@ +'use strict'; + +describe( 'legacy Revision', () => { + // Cache deletion ensures tests will execute for both legacy and module paths + // Doing this twice protects against changes in test execution order + const testsFile = __dirname + '/content.v1/Revision.js'; + delete require.cache[ testsFile ]; + require( testsFile ).init( 'rest.php/v1' ); + delete require.cache[ testsFile ]; +} ); |