aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJiri Vanek <[email protected]>2012-06-05 16:14:42 +0200
committerJiri Vanek <[email protected]>2012-06-05 16:14:42 +0200
commit31100d1348be0847c96afb270089161da41ca9ed (patch)
treeef19046a99eef6c9eeac575414884259735f19b6
parent99598df7c4a6b49d290963b2b4a9d92045e6d5b6 (diff)
isDateInRange renamed to isDateInRange_internallForIcedTeaWebTesting
-rw-r--r--ChangeLog8
-rw-r--r--netx/net/sourceforge/jnlp/runtime/pac-funcs.js16
-rw-r--r--tests/netx/pac/pac-funcs-test.js14
3 files changed, 23 insertions, 15 deletions
diff --git a/ChangeLog b/ChangeLog
index 09f6f74..0d11ca9 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,11 @@
+2012-06-05 Jiri Vanek <[email protected]>
+
+ isDateInRange renamed to isDateInRange_internallForIcedTeaWebTesting
+ * netx/net/sourceforge/jnlp/runtime/pac-funcs.js: and
+ * tests/netx/pac/pac-funcs-test.js:
+ (isDateInRange): Renamed to isDateInRange_internallForIcedTeaWebTesting.
+ (isDateInRange_internallForIcedTeaWebTesting): New function
+
2012-06-04 Saad Mohammad <[email protected]>
Added signed jnlp file tests.
diff --git a/netx/net/sourceforge/jnlp/runtime/pac-funcs.js b/netx/net/sourceforge/jnlp/runtime/pac-funcs.js
index 3028706..de074f2 100644
--- a/netx/net/sourceforge/jnlp/runtime/pac-funcs.js
+++ b/netx/net/sourceforge/jnlp/runtime/pac-funcs.js
@@ -326,19 +326,19 @@ function weekdayRange() {
*/
function dateRange() {
switch (arguments.length) {
- case 1: return isDateInRange(new Date(),arguments[0]);
- case 2: return isDateInRange(new Date(),arguments[0],arguments[1]);
- case 3: return isDateInRange(new Date(),arguments[0],arguments[1],arguments[2]);
- case 4: return isDateInRange(new Date(),arguments[0],arguments[1],arguments[2],arguments[3]);
- case 5: return isDateInRange(new Date(),arguments[0],arguments[1],arguments[2],arguments[3],arguments[4]);
- case 6: return isDateInRange(new Date(),arguments[0],arguments[1],arguments[2],arguments[3],arguments[4],arguments[5]);
- case 7: return isDateInRange(new Date(),arguments[0],arguments[1],arguments[2],arguments[3],arguments[4],arguments[5],arguments[6]); //GMT
+ case 1: return isDateInRange_internallForIcedTeaWebTesting(new Date(),arguments[0]);
+ case 2: return isDateInRange_internallForIcedTeaWebTesting(new Date(),arguments[0],arguments[1]);
+ case 3: return isDateInRange_internallForIcedTeaWebTesting(new Date(),arguments[0],arguments[1],arguments[2]);
+ case 4: return isDateInRange_internallForIcedTeaWebTesting(new Date(),arguments[0],arguments[1],arguments[2],arguments[3]);
+ case 5: return isDateInRange_internallForIcedTeaWebTesting(new Date(),arguments[0],arguments[1],arguments[2],arguments[3],arguments[4]);
+ case 6: return isDateInRange_internallForIcedTeaWebTesting(new Date(),arguments[0],arguments[1],arguments[2],arguments[3],arguments[4],arguments[5]);
+ case 7: return isDateInRange_internallForIcedTeaWebTesting(new Date(),arguments[0],arguments[1],arguments[2],arguments[3],arguments[4],arguments[5],arguments[6]); //GMT
default:
return false;
}
}
-function isDateInRange() {
+function isDateInRange_internallForIcedTeaWebTesting() {
function isDate(date) {
if (typeof(date) === 'number' && (date <= 31 && date >= 1)) {
diff --git a/tests/netx/pac/pac-funcs-test.js b/tests/netx/pac/pac-funcs-test.js
index bd50035..8a45952 100644
--- a/tests/netx/pac/pac-funcs-test.js
+++ b/tests/netx/pac/pac-funcs-test.js
@@ -492,13 +492,13 @@ function testDateRange2() {
var aYearFromNow = new Date(current.getFullYear()+1, current.getMonth()+1, current.getDate()+1);
var later = [aYearFromNow.getDate(), aYearFromNow.getMonth(), aYearFromNow.getFullYear()];
- runTest(isDateInRange, [ true, current,
+ runTest(isDateInRange_internallForIcedTeaWebTesting, [ true, current,
today[0], monthToStr(today[1]) , tomorrow[0], monthToStr(tomorrow[1]) ]);
- runTest(isDateInRange, [ true, current,
+ runTest(isDateInRange_internallForIcedTeaWebTesting, [ true, current,
yesterday[0], monthToStr(yesterday[1]) , tomorrow[0], monthToStr(tomorrow[1]) ]);
- runTest(isDateInRange, [ true, current,
+ runTest(isDateInRange_internallForIcedTeaWebTesting, [ true, current,
yesterday[0], monthToStr(yesterday[1]), yesterday[2], tomorrow[0], monthToStr(tomorrow[1]), tomorrow[2] ]);
- runTest(isDateInRange, [ false, current,
+ runTest(isDateInRange_internallForIcedTeaWebTesting, [ false, current,
tomorrow[0], monthToStr(tomorrow[1]), tomorrow[2], later[0], monthToStr(later[1]), later[2] ]);
}
@@ -528,11 +528,11 @@ function testDateRange3() {
var yesterday = incDate(current,'day',-1);
var today = incDate(current,'day',0);
var tomorrow = incDate(current,'day',1);
- runTest(isDateInRange, [ true, current,
+ runTest(isDateInRange_internallForIcedTeaWebTesting, [ true, current,
yesterday[0], monthToStr(yesterday[1]) , today[0], monthToStr(today[1]) ]);
- runTest(isDateInRange, [ true, current,
+ runTest(isDateInRange_internallForIcedTeaWebTesting, [ true, current,
yesterday[0], monthToStr(yesterday[1]) , tomorrow[0], monthToStr(tomorrow[1]) ]);
- runTest(isDateInRange, [ true, current,
+ runTest(isDateInRange_internallForIcedTeaWebTesting, [ true, current,
yesterday[0], monthToStr(yesterday[1]), yesterday[2], tomorrow[0], monthToStr(tomorrow[1]), tomorrow[2] ]);
}
}