Sha256: 62bf8364130e627d1f757295c6d61e71f951800a493be548ba3c0967f8419a2d

Contents?: true

Size: 637 Bytes

Versions: 3

Compression:

Stored size: 637 Bytes

Contents

require "spec_helper"

describe Brightbox::FirewallRule do

  describe "#destroy", :vcr, :broken_1_8 do
    context "when rule exists" do
      before do
        policy_options = {}
        @policy = Brightbox::FirewallPolicy.create(policy_options)

        rule_options = {
          :destination => "0.0.0.0/0",
          :destination_port => "1080",
          :protocol => "tcp",
          :firewall_policy_id => @policy.id
        }
        @rule = Brightbox::FirewallRule.create(rule_options)
      end

      it "destroys a rule" do
        expect {
          @rule.destroy
        }.to_not raise_error
      end
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
brightbox-cli-1.1.0 spec/unit/brightbox/firewall_rule/destroy_spec.rb
brightbox-cli-1.0.0 spec/unit/brightbox/firewall_rule/destroy_spec.rb
brightbox-cli-1.0.0.rc2 spec/unit/brightbox/firewall_rule/destroy_spec.rb