Sha256: 9ab66afbde96c9bec0e4068673f203746b2ad5121d7f28a265a8c2672f4953ad

Contents?: true

Size: 718 Bytes

Versions: 22

Compression:

Stored size: 718 Bytes

Contents

require File.dirname(__FILE__) + '/../lib/yawast'
require File.dirname(__FILE__) + '/base'

class TestScannerCms < Minitest::Test
  include TestBase

  def test_generator_tag_valid
    body = File.read(File.dirname(__FILE__) + '/data/cms_wordpress_body.txt')
    override_stdout
    Yawast::Scanner::Cms.get_generator body

    assert stdout_value.include?('WordPress'), "Unexpected generator tag: #{stdout_value}"

    restore_stdout
  end

  def test_generator_tag_invalid
    body = File.read(File.dirname(__FILE__) + '/data/cms_none_body.txt')
    override_stdout
    Yawast::Scanner::Cms.get_generator body

    assert stdout_value == '', "Unexpected generator tag: #{stdout_value}"

    restore_stdout
  end
end

Version data entries

22 entries across 22 versions & 1 rubygems

Version Path
yawast-0.7.0.beta1 test/test_scan_cms.rb
yawast-0.6.0 test/test_scan_cms.rb
yawast-0.6.0.beta6 test/test_scan_cms.rb
yawast-0.6.0.beta5 test/test_scan_cms.rb
yawast-0.6.0.beta4 test/test_scan_cms.rb
yawast-0.6.0.beta3 test/test_scan_cms.rb
yawast-0.6.0.beta2 test/test_scan_cms.rb
yawast-0.6.0.beta1 test/test_scan_cms.rb
yawast-0.5.2 test/test_scan_cms.rb
yawast-0.5.1 test/test_scan_cms.rb
yawast-0.5.1.beta1 test/test_scan_cms.rb
yawast-0.5.0 test/test_scan_cms.rb
yawast-0.5.0.beta8 test/test_scan_cms.rb
yawast-0.5.0.beta7 test/test_scan_cms.rb
yawast-0.5.0.beta6 test/test_scan_cms.rb
yawast-0.5.0.beta5 test/test_scan_cms.rb
yawast-0.5.0.beta4 test/test_scan_cms.rb
yawast-0.5.0.beta3 test/test_scan_cms.rb
yawast-0.5.0.beta2 test/test_scan_cms.rb
yawast-0.5.0.beta1 test/test_scan_cms.rb