Sha256: c7354ea9c5e960ae4bea91a20daca291325b8f03562aeaca3c416e1b1cec7298

Contents?: true

Size: 485 Bytes

Versions: 5

Compression:

Stored size: 485 Bytes

Contents

#
# Mock Service Implementation
#

require 'service'

module DiffNews

  class MockService < Service
    attr_reader :title, :teaser, :text

    def initialize url
      @title = "Mock Title"
      @teaser = "Mock Teaser"
      @text = "Mock Text"

      super url
    end

    def self.provider
      'mock_service'
    end

    def self.base_url
      'none'
    end

    def self.valid_url
      /mock_me/
    end
   
    def load_document
    end

    register_service
  end

end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
diff_news-0.9.7 lib/news_service/mock.rb
diff_news-0.9.6 lib/news_service/mock.rb
diff_news-0.9.5 lib/news_service/mock.rb
diff_news-0.9.4 lib/news_service/mock.rb
diff_news-0.9.3 lib/news_service/mock.rb