Sha256: f7c4815eb9bed218f62bcde69053e838d0a8f9c563879d60967982b0f54aabe4

Contents?: true

Size: 762 Bytes

Versions: 31

Compression:

Stored size: 762 Bytes

Contents

Metasploit::Model::Spec.shared_examples_for 'Module::Target' do
  context 'factories' do
    context module_target_factory do
      subject(module_target_factory) do
        FactoryGirl.build(module_target_factory)
      end

      it { should be_valid }
    end
  end

  context 'mass assignment security' do
    it { should allow_mass_assignment_of(:name) }
  end

  context 'search' do
    context 'attributes' do
      it_should_behave_like 'search_attribute', :name, :type => :string
    end
  end

  context 'validations' do
    it { should validate_presence_of(:module_instance) }
    it { should validate_presence_of(:name) }
    it { should validate_presence_of :target_architectures }
    it { should validate_presence_of :target_platforms }
  end
end

Version data entries

31 entries across 31 versions & 1 rubygems

Version Path
metasploit-model-0.28.0 spec/support/shared/examples/metasploit/model/module/target.rb
metasploit-model-0.28.0-java spec/support/shared/examples/metasploit/model/module/target.rb
metasploit-model-0.28.0.pre.engine.pre.requires spec/support/shared/examples/metasploit/model/module/target.rb
metasploit-model-0.27.4 spec/support/shared/examples/metasploit/model/module/target.rb
metasploit-model-0.27.4-java spec/support/shared/examples/metasploit/model/module/target.rb
metasploit-model-0.27.3 spec/support/shared/examples/metasploit/model/module/target.rb
metasploit-model-0.27.3-java spec/support/shared/examples/metasploit/model/module/target.rb
metasploit-model-0.27.2 spec/support/shared/examples/metasploit/model/module/target.rb
metasploit-model-0.27.2-java spec/support/shared/examples/metasploit/model/module/target.rb
metasploit-model-0.27.1 spec/support/shared/examples/metasploit/model/module/target.rb
metasploit-model-0.27.1-java spec/support/shared/examples/metasploit/model/module/target.rb
metasploit-model-0.27.0 spec/support/shared/examples/metasploit/model/module/target.rb
metasploit-model-0.27.0-java spec/support/shared/examples/metasploit/model/module/target.rb
metasploit-model-0.27.0.pre.dep.pre.railties spec/support/shared/examples/metasploit/model/module/target.rb
metasploit-model-0.26.1-java spec/support/shared/examples/metasploit/model/module/target.rb
metasploit-model-0.26.1 spec/support/shared/examples/metasploit/model/module/target.rb
metasploit-model-0.25.7 spec/support/shared/examples/metasploit/model/module/target.rb
metasploit-model-0.25.7-java spec/support/shared/examples/metasploit/model/module/target.rb
metasploit-model-0.25.6 spec/support/shared/examples/metasploit/model/module/target.rb
metasploit-model-0.25.6-java spec/support/shared/examples/metasploit/model/module/target.rb