bugfixing and rspec tests

This commit is contained in:
Christian Mehlmauer
2012-09-19 22:25:13 +02:00
parent d677dd83ee
commit 7ca2916215
6 changed files with 18 additions and 14 deletions

View File

@@ -22,7 +22,9 @@ describe WpPlugin do
before :each do
@instance = WpItem.new(:url => "http://sub.example.com/path/to/wordpress/",
:path => "plugins/test/asdf.php",
:vulns_xml => "XXX.xml"
:vulns_xml => "XXX.xml",
:name => "test",
:vulns_xpath => "XX"
)
end
@@ -174,7 +176,8 @@ describe WpPlugin do
it "should return false" do
instance2 = WpItem.new(:url => "http://sub.example.com/path/to/wordpress/",
:path => "plugins/newname/asdf.php",
:vulns_xml => "XXX.xml"
:vulns_xml => "XXX.xml",
:vulns_xpath => "XX"
)
(@instance==instance2).should == false
end
@@ -182,7 +185,8 @@ describe WpPlugin do
it "should return true" do
instance2 = WpItem.new(:url => "http://sub.example.com/path/to/wordpress/",
:path => "plugins/test/asdf.php",
:vulns_xml => "XXX.xml"
:vulns_xml => "XXX.xml",
:vulns_xpath => "XX"
)
(@instance==instance2).should == true
end