Also test for nonmatching passwords
parent
1410477fe9
commit
63c3832d7d
|
@ -141,15 +141,29 @@ describe Msf::Ui::Console::CommandDispatcher::Db do
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
context "when the credential is absent" do
|
context "when the credential is absent" do
|
||||||
it "should return a blank set" do
|
context "due to a nonmatching username" do
|
||||||
db.cmd_creds("-u", nomatch_username)
|
it "should return a blank set" do
|
||||||
@output.should =~ [
|
db.cmd_creds("-u", nomatch_username)
|
||||||
"===========",
|
@output.should =~ [
|
||||||
"Credentials",
|
"===========",
|
||||||
"",
|
"Credentials",
|
||||||
"---- ------- ------ ------- ----- ------------",
|
"",
|
||||||
"host service public private realm private_type"
|
"---- ------- ------ ------- ----- ------------",
|
||||||
]
|
"host service public private realm private_type"
|
||||||
|
]
|
||||||
|
end
|
||||||
|
end
|
||||||
|
context "due to a nonmatching password" do
|
||||||
|
it "should return a blank set" do
|
||||||
|
db.cmd_creds("-P", nomatch_password)
|
||||||
|
@output.should =~ [
|
||||||
|
"===========",
|
||||||
|
"Credentials",
|
||||||
|
"",
|
||||||
|
"---- ------- ------ ------- ----- ------------",
|
||||||
|
"host service public private realm private_type"
|
||||||
|
]
|
||||||
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in New Issue