summaryrefslogtreecommitdiff
path: root/testing/resources/javascript
diff options
context:
space:
mode:
Diffstat (limited to 'testing/resources/javascript')
-rw-r--r--testing/resources/javascript/document_methods.in12
-rw-r--r--testing/resources/javascript/document_methods_expected.txt3
2 files changed, 15 insertions, 0 deletions
diff --git a/testing/resources/javascript/document_methods.in b/testing/resources/javascript/document_methods.in
index 3cd3330b87..1c53dc24b5 100644
--- a/testing/resources/javascript/document_methods.in
+++ b/testing/resources/javascript/document_methods.in
@@ -214,6 +214,17 @@ function testGetPrintParams() {
// TODO(tsepez): test success cases.
}
+function testGotoNamedDest() {
+ // Method is present.
+ expect('typeof this.gotoNamedDest', 'function');
+
+ // Method needs exactly one argument.
+ expectError('this.gotoNamedDest()');
+ expectError('this.gotoNamedDest(1, 2)');
+
+ // TODO(tonikitoo): test success cases.
+}
+
function testMailDoc() {
// Method is present.
expect('typeof this.mailDoc', 'function');
@@ -303,6 +314,7 @@ try {
testGetPageNthWordQuads();
testGetPageNumWords();
testGetPrintParams();
+ testGotoNamedDest();
testMailDoc();
testMailForm();
testPrint();
diff --git a/testing/resources/javascript/document_methods_expected.txt b/testing/resources/javascript/document_methods_expected.txt
index 26f7b542dd..d66de8b119 100644
--- a/testing/resources/javascript/document_methods_expected.txt
+++ b/testing/resources/javascript/document_methods_expected.txt
@@ -97,6 +97,9 @@ Alert: PASS: this.getPageNumWords(0, "clams", [1, 2]) = 2
Alert: PASS: this.getPageNumWords(-1) threw error Document.getPageNumWords: Incorrect parameter value.
Alert: PASS: this.getPageNumWords(6) threw error Document.getPageNumWords: Incorrect parameter value.
Alert: PASS: typeof this.getPrintParams = function
+Alert: PASS: typeof this.gotoNamedDest = function
+Alert: PASS: this.gotoNamedDest() threw error Document.gotoNamedDest: Incorrect number of parameters passed to function.
+Alert: PASS: this.gotoNamedDest(1, 2) threw error Document.gotoNamedDest: Incorrect number of parameters passed to function.
Alert: PASS: typeof this.mailDoc = function
Alert: PASS: typeof this.mailForm = function
Alert: PASS: typeof this.print = function