Use the SimpleLinkService when running "annotations" reference tests

Rather than (basically) duplicating the `SimpleLinkService` in `test/driver.js`, with potential test failuires if you forget to update the test mock, it seems much nicer to just re-use the viewer component.

Note that `SimpleLinkService` is already bundled into the `build/components/pdf_viewer.js` file. Hence we only need to expose it similar to the other viewer components in that file, and make sure that the `gulp components` command runs as part of the test-setup.
This commit is contained in:
Jonas Jenwald 2017-09-12 14:29:23 +02:00
parent f2618eb2e4
commit 1ebbdc253a
4 changed files with 9 additions and 42 deletions

View file

@ -1085,22 +1085,22 @@ gulp.task('publish', ['generic'], function (done) {
});
});
gulp.task('test', ['generic'], function () {
gulp.task('test', ['generic', 'components'], function () {
return streamqueue({ objectMode: true, },
createTestSource('unit'), createTestSource('browser'));
});
gulp.task('bottest', ['generic'], function () {
gulp.task('bottest', ['generic', 'components'], function () {
return streamqueue({ objectMode: true, },
createTestSource('unit'), createTestSource('font'),
createTestSource('browser (no reftest)'));
});
gulp.task('browsertest', ['generic'], function () {
gulp.task('browsertest', ['generic', 'components'], function () {
return createTestSource('browser');
});
gulp.task('unittest', ['generic'], function () {
gulp.task('unittest', ['generic', 'components'], function () {
return createTestSource('unit');
});
@ -1108,11 +1108,11 @@ gulp.task('fonttest', function () {
return createTestSource('font');
});
gulp.task('makeref', ['generic'], function (done) {
gulp.task('makeref', ['generic', 'components'], function (done) {
makeRef(done);
});
gulp.task('botmakeref', ['generic'], function (done) {
gulp.task('botmakeref', ['generic', 'components'], function (done) {
makeRef(done, true);
});