Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
smradius
smradius
Commits
6a79baab
Commit
6a79baab
authored
May 15, 2019
by
Nigel Kukard
Browse files
Added unit test for reply attributes
parent
893bc2f4
Changes
1
Hide whitespace changes
Inline
Side-by-side
t/200-dbtests.t
View file @
6a79baab
...
...
@@ -181,6 +181,11 @@ if ($child = fork()) {
$user1_ID
,'
User-Password
','
==
','
test123
'
);
my
$user1attr2_ID
=
testDBInsert
("
Create user 'testuser1' attribute 'Framed-IP-Address'
",
"
INSERT INTO user_attributes (UserID,Name,Operator,Value,Disabled) VALUES (?,?,?,?,0)
",
$user1_ID
,'
Framed-IP-Address
','
:=
','
10.0.0.1
'
);
$res
=
smradius::
client
->
run
(
"
--raddb
","
dicts
",
"
127.0.0.1
",
...
...
@@ -191,6 +196,7 @@ if ($child = fork()) {
);
is
(
ref
(
$res
),"
HASH
","
smradclient should return a HASH
");
is
(
$res
->
{'
response
'}
->
{'
code
'},"
Access-Accept
","
Check our return is 'Access-Accept' for bare user blank '' realm
");
is
(
$res
->
{'
response
'}
->
{'
attributes
'}
->
{'
Framed-IP-Address
'},"
10.0.0.1
","
Check that an attribute is replied with if setup
");
#
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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