Sha256: bef13a04b0023a807ace8fe70108d0613740c87b2bc459d34220704c92fae564

Contents?: true

Size: 638 Bytes

Versions: 28

Compression:

Stored size: 638 Bytes

Contents

require File.dirname(__FILE__) + '/../../spec_helper'

describe RequestLogAnalyzer::Filter::Anonymize, 'anonymize request' do

  before(:each) do
    @filter = RequestLogAnalyzer::Filter::Anonymize.new(testing_format)
  end
  
  it "should anonimize ip" do
    @filter.filter(request(:ip => '123.123.123.123'))[:ip].should_not eql('123.123.123.123')
  end

  it "should anonimize url" do
    @filter.filter(request(:url => 'https://test.mysite.com/employees'))[:url].should eql('http://example.com/employees')
  end

  it "should fuzz durations" do
    @filter.filter(request(:duration => 100))[:duration].should_not eql(100)
  end
  
end

Version data entries

28 entries across 28 versions & 2 rubygems

Version Path
request-log-analyzer-1.3.2 spec/unit/filter/anonymize_filter_spec.rb
request-log-analyzer-1.3.1 spec/unit/filter/anonymize_filter_spec.rb
request-log-analyzer-1.3.0 spec/unit/filter/anonymize_filter_spec.rb
request-log-analyzer-1.2.9 spec/unit/filter/anonymize_filter_spec.rb
request-log-analyzer-1.2.8 spec/unit/filter/anonymize_filter_spec.rb
request-log-analyzer-1.2.7 spec/unit/filter/anonymize_filter_spec.rb
request-log-analyzer-1.2.6 spec/unit/filter/anonymize_filter_spec.rb
request-log-analyzer-1.2.3 spec/unit/filter/anonymize_filter_spec.rb