File: twitter_text_spec.rb

package info (click to toggle)
ruby-twitter-text 1.10.0%2Bgem-1
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 372 kB
  • ctags: 207
  • sloc: ruby: 2,928; makefile: 2
file content (21 lines) | stat: -rw-r--r-- 409 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
# encoding: utf-8
require File.dirname(__FILE__) + '/spec_helper'

major, minor, patch = RUBY_VERSION.split('.')
if major.to_i == 1 && minor.to_i < 9
  describe "base" do
    before do
      $KCODE = 'NONE'
    end

    after do
      $KCODE = 'u'
    end

    it "should raise with invalid KCODE on Ruby < 1.9" do
      lambda do
        require 'twitter-text'
      end.should raise_error
    end
  end
end