<commit_before><commit_msg>Add implementation for #list_addresses service.<commit_after>module Fog
  module HP
    class Compute
      class Real

        # List all server addresses
        #
        # ==== Parameters
        # * server_id<~Integer> - Id of server to list addresses for
        #
        # ==== Returns
        # * response<~Excon::Response>:
        #   * body<~Hash>:
        #   * 'addresses'<~Array>:
        #     * 'public'<~Array> - Public ip addresses
        #     * 'private'<~Array> - Private ip addresses
        def list_addresses(server_id)
          request(
            :expects  => [200, 203],
            :method   => 'GET',
            :path     => "servers/#{server_id}/ips.json"
          )
        end

      end

      class Mock

        def list_addresses(server_id)
          response = Excon::Response.new
          if server = list_servers_detail.body['servers'].detect {|_| _['id'] == server_id}
            response.status = [200, 203][rand(1)]
            response.body = { 'addresses' => server['addresses'] }
            response
          else
            raise Fog::HP::Compute::NotFound
          end
        end

      end
    end
  end
end
{'fraction_non_alphanumeric': 0.1196652719665272, 'fraction_numerical': 0.010878661087866108, 'mean_word_length': 1.6756152125279642, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 13, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, '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': '6262278', 'n_tokens_mistral': 352, 'n_tokens_neox': 338, 'n_words': 76}