<commit_before>module J7W1
  class Configuration
    module IOSEndpoint
      def sandbox?
        @sandbox
      end

      def arn
        self[:arn]
      end

      def confirm_sandbox
        arn =~ /:app\/APNS_SANDBOX\//
      end
    end

    module AndroidEndpoint
      def arn
        self[:arn]
      end
    end 

    module Account
      [:access_key_id, :secret_access_key, :region].each do |attr|
        define_method(attr){self[attr]}
      end
    end

    def initialize(configuration_values)
      @values = configuration_values
      if ios_endpoint
        ios_endpoint.extend(IOSEndpoint)
        ios_endpoint.confirm_sandbox
      end
      android_endpoint.extend(AndroidEndpoint) if android_endpoint
      account.extend(Account)
    end

    def account
      @values[:account]
    end

    def ios_endpoint<commit_msg>confirm_sandbox should set the result of the confirmation.<commit_after>module J7W1
  class Configuration
    module IOSEndpoint
      def sandbox?
        @sandbox
      end

      def arn
        self[:arn]
      end

      def confirm_sandbox
        @sandbox = (arn =~ /:app\/APNS_SANDBOX\//)
      end
    end

    module AndroidEndpoint
      def arn
        self[:arn]
      end
    end 

    module Account
      [:access_key_id, :secret_access_key, :region].each do |attr|
        define_method(attr){self[attr]}
      end
    end

    def initialize(configuration_values)
      @values = configuration_values
      if ios_endpoint
        ios_endpoint.extend(IOSEndpoint)
        ios_endpoint.confirm_sandbox
      end
      android_endpoint.extend(AndroidEndpoint) if android_endpoint
      account.extend(Account)
    end

    def account
      @values[:account]
    end

    def ios_endpoint
{'fraction_non_alphanumeric': 0.06457142857142857, 'fraction_numerical': 0.002285714285714286, 'mean_word_length': 2.121212121212121, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, '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': '5597912', 'n_tokens_mistral': 546, 'n_tokens_neox': 510, 'n_words': 121}