ical2gcal 0.5.0 → 0.7.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.rspec +1 -0
- data/Gemfile +5 -17
- data/HISTORY.md +14 -0
- data/README.rdoc +1 -1
- data/Rakefile +3 -56
- data/{bin → exe}/ical2gcal +0 -0
- data/ical2gcal.gemspec +28 -78
- data/lib/google.rb +12 -8
- data/lib/ical2gcal/version.rb +5 -0
- data/lib/ical2gcal.rb +2 -2
- data/monkey_patches/multi_json.rb +24 -0
- metadata +42 -125
- data/.travis.yml +0 -4
- data/VERSION +0 -1
- data/spec/ical2gcal_spec.rb +0 -4
- data/spec/ics/events_spec.rb +0 -27
- data/spec/ics/list_spec.rb +0 -60
- data/spec/spec_helper.rb +0 -12
- data/spec/support/ics_list.txt +0 -1
- data/spec/support/japanese_holidays.ics +0 -728
data/spec/ics/list_spec.rb
DELETED
@@ -1,60 +0,0 @@
|
|
1
|
-
require File.dirname( __FILE__ ) + '/../spec_helper'
|
2
|
-
|
3
|
-
ICS_FILE = File.dirname( __FILE__ ) + '/../support/ics_list.txt'
|
4
|
-
JAPANESE_HOLIDAYS = 'https://www.google.com/calendar/ical/japanese%40holiday.calendar.google.com/public/basic.ics'
|
5
|
-
|
6
|
-
describe Ical2gcal::Ics::List do
|
7
|
-
describe 'import' do
|
8
|
-
context 'localfile' do
|
9
|
-
it {
|
10
|
-
Ical2gcal::Ics::List.new( ICS_FILE ).import.class.should be Array
|
11
|
-
}
|
12
|
-
end
|
13
|
-
context 'uri' do
|
14
|
-
it {
|
15
|
-
Ical2gcal::Ics::List.new( JAPANESE_HOLIDAYS ).import.class.should be Array
|
16
|
-
}
|
17
|
-
end
|
18
|
-
context 'with uri' do
|
19
|
-
it {
|
20
|
-
Ical2gcal::Ics::List.new.import( ICS_FILE ).class.should be Array
|
21
|
-
}
|
22
|
-
end
|
23
|
-
context 'no data given' do
|
24
|
-
it {
|
25
|
-
Ical2gcal::Ics::List.new.import.should be_nil
|
26
|
-
}
|
27
|
-
end
|
28
|
-
end
|
29
|
-
|
30
|
-
describe 'list' do
|
31
|
-
context 'localfile' do
|
32
|
-
it {
|
33
|
-
ics = Ical2gcal::Ics::List.new( ICS_FILE )
|
34
|
-
ics.import
|
35
|
-
ics.list.class.should be Array
|
36
|
-
}
|
37
|
-
end
|
38
|
-
context 'no data given' do
|
39
|
-
it {
|
40
|
-
ics = Ical2gcal::Ics::List.new
|
41
|
-
ics.import
|
42
|
-
ics.list.class.should be Array
|
43
|
-
ics.list.size == 0
|
44
|
-
}
|
45
|
-
end
|
46
|
-
end
|
47
|
-
|
48
|
-
describe 'with_scheme?' do
|
49
|
-
context 'localfile' do
|
50
|
-
it {
|
51
|
-
Ical2gcal::Ics::List.new( ICS_FILE ).with_scheme?.should == false
|
52
|
-
}
|
53
|
-
end
|
54
|
-
context 'uri' do
|
55
|
-
it {
|
56
|
-
Ical2gcal::Ics::List.new( JAPANESE_HOLIDAYS ).with_scheme?.should == true
|
57
|
-
}
|
58
|
-
end
|
59
|
-
end
|
60
|
-
end
|
data/spec/spec_helper.rb
DELETED
@@ -1,12 +0,0 @@
|
|
1
|
-
$LOAD_PATH.unshift(File.join(File.dirname(__FILE__), '..', 'lib'))
|
2
|
-
$LOAD_PATH.unshift(File.dirname(__FILE__))
|
3
|
-
require 'rspec'
|
4
|
-
require 'ical2gcal'
|
5
|
-
|
6
|
-
# Requires supporting files with custom matchers and macros, etc,
|
7
|
-
# in ./support/ and its subdirectories.
|
8
|
-
Dir["#{File.dirname(__FILE__)}/support/**/*.rb"].each {|f| require f}
|
9
|
-
|
10
|
-
RSpec.configure do |config|
|
11
|
-
|
12
|
-
end
|
data/spec/support/ics_list.txt
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
https://www.google.com/calendar/ical/japanese%40holiday.calendar.google.com/public/basic.ics
|