# HG changeset patch # User Nicholas Jillings # Date 1492590647 -3600 # Node ID 4bf2f7627cdbfdb04c52d69d3778ca4278610bb7 # Parent 9c3f50d6e544f319a80cf6b5046974c9704c4b38# Parent a13adc8f8d3de8ea45ae562cd2edd232566791d0 Merge branch 'master' into vnext diff -r 9c3f50d6e544 -r 4bf2f7627cdb js/core.js --- a/js/core.js Sat Apr 15 12:06:19 2017 +0100 +++ b/js/core.js Wed Apr 19 09:30:47 2017 +0100 @@ -873,7 +873,7 @@ function processNumber(node) { var input = this.popupContent.getElementsByTagName('input')[0]; - if (node.mandatory === true && input.value.length === 0) { + if (node.specification.mandatory === true && input.value.length === 0) { interfaceContext.lightbox.post("Error", 'This question is mandatory. Please enter a number'); return false; } @@ -882,12 +882,12 @@ interfaceContext.lightbox.post("Error", 'Please enter a valid number'); return false; } - if (enteredNumber < node.min && node.min !== null) { - interfaceContext.lightbox.post("Error", 'Number is below the minimum value of ' + node.min); + if (enteredNumber < node.specification.min && node.specification.min !== null) { + interfaceContext.lightbox.post("Error", 'Number is below the minimum value of ' + node.specification.min); return false; } - if (enteredNumber > node.max && node.max !== null) { - interfaceContext.lightbox.post("Error", 'Number is above the maximum value of ' + node.max); + if (enteredNumber > node.specification.max && node.specification.max !== null) { + interfaceContext.lightbox.post("Error", 'Number is above the maximum value of ' + node.specification.max); return false; } node.response = input.value; diff -r 9c3f50d6e544 -r 4bf2f7627cdb test_create/interface-specs.xml --- a/test_create/interface-specs.xml Sat Apr 15 12:06:19 2017 +0100 +++ b/test_create/interface-specs.xml Wed Apr 19 09:30:47 2017 +0100 @@ -500,7 +500,7 @@ - Each page has only two audio fragments. The user must select one of the two fragments to proceed. There can be one hidden reference. + A page contains a number of audio fragments. The user must select one of the fragments to proceed. There can be a hidden reference. @@ -520,7 +520,7 @@ - Each page has two audio fragments presented as A and B. The test duplicates one of the fragments and presents it as X. The user must choose which, out of A or B, is closest to X. + Each page has a number of audio fragments presented as A and B (and C, ...). The test duplicates one of the fragments and presents it as X. The user must choose which, out of A or B (or C, ...), is closest to X. diff -r 9c3f50d6e544 -r 4bf2f7627cdb tests/pool.xml --- a/tests/pool.xml Sat Apr 15 12:06:19 2017 +0100 +++ b/tests/pool.xml Wed Apr 19 09:30:47 2017 +0100 @@ -1,6 +1,6 @@ - + testTimer elementTimer