<commit_before><commit_msg>Added based specs for Tracroute (closes #24).<commit_after>require 'spec_helper'
require 'nmap/traceroute'

describe Traceroute do
  subject { @xml.hosts.first.traceroute }

  describe "#port" do
    subject { super().port }

    it { should be_kind_of(Integer) }
    it { should be > 0 }
    it { should be < 65535 }
  end

  describe "#protocol" do
    subject { super().protocol }

    it { should be_kind_of(Symbol) }
    it { should be_one_of(:tcp, :udp) }
  end

  describe "#each" do
    subject { super().each }

    it { should all_be_kind_of(Hop) }
  end
end
{'fraction_non_alphanumeric': 0.11764705882352941, 'fraction_numerical': 0.013445378151260505, 'mean_word_length': 3.1971830985915495, 'pattern_counts': {'":': 0, '<': 4, '<?xml version=': 0, '>': 4, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 1}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3675776', 'n_tokens_mistral': 219, 'n_tokens_neox': 202, 'n_words': 55}