Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
sympa
sympa
Commits
ed2c0831
Unverified
Commit
ed2c0831
authored
Nov 23, 2019
by
IKEDA Soji
Committed by
GitHub
Nov 23, 2019
Browse files
Merge pull request #782 from ikedas/scenario_compilation by ikedas
Enhancements on scenarios
parents
8f508542
6ac59b9c
Changes
7
Expand all
Hide whitespace changes
Inline
Side-by-side
.gitlab-ci.yml
View file @
ed2c0831
...
...
@@ -12,7 +12,7 @@
-
./configure
-
cd src; make; cd ..
-
make check-local TEST_FILES='xt/perltidy.t' ||
true
-
make check-local TEST_FILES='t/compile_executables.t t/compile_modules.t t/Language.t t/parse_templates.t t/pod-syntax.t'
-
make check-local TEST_FILES='t/compile_executables.t t/compile_modules.t t/Language.t
t/compile_scenarios.t
t/parse_templates.t t/pod-syntax.t'
-
coverage-report
-
make clean
...
...
.travis.yml
View file @
ed2c0831
...
...
@@ -43,7 +43,7 @@ script:
-
./configure
-
cd src; make; cd ..
-
make check-local TEST_FILES='xt/perltidy.t' ||
true
-
make check-local TEST_FILES='t/compile_executables.t t/compile_modules.t t/Language.t t/parse_templates.t t/pod-syntax.t'
-
make check-local TEST_FILES='t/compile_executables.t t/compile_modules.t t/Language.t
t/compile_scenarios.t
t/parse_templates.t t/pod-syntax.t'
after_success
:
-
coverage-report
...
...
Makefile.am
View file @
ed2c0831
...
...
@@ -33,6 +33,7 @@ check_SCRIPTS = \
t/Regexps.t
\
t/compile_modules.t
\
t/compile_executables.t
\
t/compile_scenarios.t
\
t/Database_LDAP.t
\
t/parse_templates.t
\
t/pod-syntax.t
\
...
...
default/mail_tt2/listmaster_notification.tt2
View file @
ed2c0831
...
...
@@ -315,6 +315,13 @@ Subject: [%"Failed to parse web template"|loc|qencode%]
[%|loc(param0)%]Error: %1[%END%]
[%|loc%]Check the Sympa log files for more information.[%END%]
[% ELSIF type == 'error_performing_condition' -%]
Subject: [%"Failed to perform scenario condition"|loc|qencode%]
[%|loc%]Sympa failed to perform scenario condigion for the following reason: [%END%]
[%|loc(error)%]Error: %1[%END%]
[%|loc%]Check the Sympa log files for more information.[%END%]
[%# INTERNAL SERVER ERROR : MAIL -%]
[% ELSIF type == 'mail_intern_error' -%]
Subject: [%"Listmaster: internal server error"|loc|qencode%]
...
...
src/cgi/wwsympa.fcgi.in
View file @
ed2c0831
...
...
@@ -10182,7 +10182,7 @@ sub do_scenario_test {
my $result = Sympa::Scenario->new($robot, $function)->authz(
$in{'auth_method'},
{ 'listname' => $in{'listname'},
{ 'listname' => $in{'listname'},
# FIXME: Unavailable list
'sender' => $in{'sender'},
'email' => $in{'email'},
'remote_host' => $in{'remote_host'},
...
...
src/lib/Sympa/Scenario.pm
View file @
ed2c0831
This diff is collapsed.
Click to expand it.
t/compile_scenarios.t
0 → 100644
View file @
ed2c0831
#-*- perl -*-
use
strict
;
use
warnings
;
use
English
qw(-no_match_vars)
;
use
Test::
More
;
use
Sympa::
Scenario
;
my
@files
=
<
default
/scenari/
*.*>
;
foreach
my
$file
(
@files
)
{
open
my
$fh
,
'
<
',
$file
or
die
$ERRNO
;
my
$data
=
do
{
local
$RS
;
<
$fh
>
};
close
$fh
;
my
$parsed
=
Sympa::Scenario::
compile
('
*
',
$data
);
my
$eval_error
=
$EVAL_ERROR
;
ok
((
$parsed
and
ref
$parsed
->
{
sub
}
eq
'
CODE
'),
$file
);
diag
(
$eval_error
)
if
$eval_error
;
}
done_testing
();
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment