summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xindex.pl11
-rw-r--r--reltest-form.conf8
2 files changed, 13 insertions, 6 deletions
diff --git a/index.pl b/index.pl
index 4a59893..01f59eb 100755
--- a/index.pl
+++ b/index.pl
@@ -34,8 +34,15 @@ sub meaning
return $result;
}
+my $toptext = "Sanity Test Guidelines can be found here: \
+<a href=http://qt-project.org/wiki/Sanity-Test-Guidelines> \
+http://qt-project.org/wiki/Sanity-Test-Guidelines</a><br> \
+Feel free to update them during your test to make them reusable \
+and helpful for other testers.";
+
# First create our form
-my $form = CGI::FormBuilder->new(source => 'reltest-form.conf');
+my $form = CGI::FormBuilder->new(source => 'reltest-form.conf',
+ text => $toptext);
# Check to see if we're submitted and valid
if ($form->submitted && $form->validate) {
@@ -62,7 +69,7 @@ if ($form->submitted && $form->validate) {
} else {
# Auto-fill with today's date
- my $now = strftime("%m/%d/%Y", localtime);
+ my $now = strftime("%Y-%m-%d", localtime);
$form->field(name => 'report_date',
value => $now);
$form->field(name => 'package_date',
diff --git a/reltest-form.conf b/reltest-form.conf
index 26b2eaa..d359f79 100644
--- a/reltest-form.conf
+++ b/reltest-form.conf
@@ -16,8 +16,8 @@ fields:
type: date
size: 10
required: 1
- validate: DATE
- comment: <i>MM/DD/YYYY</i>
+ validate: /^[0-9]{4}-?(0?[1-9]|1[0-2])-?(0?[1-9]|[1-2][0-9]|3[0-1])$/
+ comment: <i>YYYY-MM-DD</i>
report_name:
label: Reporters Name
@@ -30,8 +30,8 @@ fields:
type: date
size: 10
required: 1
- validate: DATE
- comment: <i>MM/DD/YYYY</i>
+ validate: /^[0-9]{4}-?(0?[1-9]|1[0-2])-?(0?[1-9]|[1-2][0-9]|3[0-1])$/
+ comment: <i>YYYY-MM-DD</i>
package_name:
label: Package name