Adds specs

This commit is contained in:
erwanlr
2020-09-10 13:41:01 +02:00
parent 61a3106b3b
commit d9f6c71015
5 changed files with 50 additions and 3 deletions

View File

@@ -35,15 +35,47 @@ describe WPScan::Finders::InterestingFindings::DuplicatorInstallerLog do
end
context 'when the body matches' do
let(:body) { File.read(fixtures.join(filename)) }
it 'returns the InterestingFinding' do
after do
expect(finder.aggressive).to eql WPScan::Model::DuplicatorInstallerLog.new(
log_url,
confidence: 100,
found_by: described_class::DIRECT_ACCESS
)
end
context 'when old versions of the file' do
let(:body) { File.read(fixtures.join('old.txt')) }
it 'returns the InterestingFinding' do
# handled in after loop above
end
end
context 'when newest versions of the file' do
context 'when PRO format 1' do
let(:body) { File.read(fixtures.join('pro.txt')) }
it 'returns the InterestingFinding' do
# handled in after loop above
end
end
context 'when PRO format 2' do
let(:body) { File.read(fixtures.join('pro2.txt')) }
it 'returns the InterestingFinding' do
# handled in after loop above
end
end
context 'when LITE' do
let(:body) { File.read(fixtures.join('lite.txt')) }
it 'returns the InterestingFinding' do
# handled in after loop above
end
end
end
end
end
end

View File

@@ -0,0 +1,5 @@
********************************************************************************
* DUPLICATOR-LITE INSTALL-LOG
* STEP1 START @ 04:10:42
* NOTICE: Do NOT post to public sites or forums
********************************************************************************

View File

@@ -0,0 +1,5 @@
********************************************************************************
* DUPLICATOR-PRO: Install-Log
* STEP1 START @ 04:10:42
* NOTICE: Do NOT post to public sites or forums
********************************************************************************

View File

@@ -0,0 +1,5 @@
********************************************************************************
DUPLICATOR PRO INSTALL-LOG
STEP1 START @ 04:10:42
NOTICE: Do NOT post to public sites or forums
********************************************************************************