calendar_date_select 1.16.4 → 2.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.gitignore +16 -3
- data/Gemfile +20 -0
- data/Gemfile.lock +111 -0
- data/History.txt +4 -0
- data/{README.txt → README.md} +6 -6
- data/Rakefile +6 -35
- data/VERSION +1 -1
- data/{public → app/assets}/images/calendar_date_select/calendar.gif +0 -0
- data/{public → app/assets}/javascripts/calendar_date_select/calendar_date_select.js +0 -0
- data/{public → app/assets}/javascripts/calendar_date_select/format_american.js +0 -0
- data/{public → app/assets}/javascripts/calendar_date_select/format_danish.js +0 -0
- data/{public → app/assets}/javascripts/calendar_date_select/format_db.js +0 -0
- data/{public → app/assets}/javascripts/calendar_date_select/format_euro_24hr.js +0 -0
- data/{public → app/assets}/javascripts/calendar_date_select/format_euro_24hr_ymd.js +0 -0
- data/{public → app/assets}/javascripts/calendar_date_select/format_finnish.js +0 -0
- data/{public → app/assets}/javascripts/calendar_date_select/format_hyphen_ampm.js +0 -0
- data/{public → app/assets}/javascripts/calendar_date_select/format_iso_date.js +0 -0
- data/{public → app/assets}/javascripts/calendar_date_select/format_italian.js +0 -0
- data/{public → app/assets}/javascripts/calendar_date_select/locale/ar.js +0 -0
- data/app/assets/javascripts/calendar_date_select/locale/cs.js +11 -0
- data/{public → app/assets}/javascripts/calendar_date_select/locale/da.js +0 -0
- data/{public → app/assets}/javascripts/calendar_date_select/locale/de.js +0 -0
- data/{public → app/assets}/javascripts/calendar_date_select/locale/es.js +0 -0
- data/{public → app/assets}/javascripts/calendar_date_select/locale/fi.js +3 -3
- data/{public → app/assets}/javascripts/calendar_date_select/locale/fr.js +0 -0
- data/app/assets/javascripts/calendar_date_select/locale/hu.js +11 -0
- data/{public → app/assets}/javascripts/calendar_date_select/locale/it.js +0 -0
- data/app/assets/javascripts/calendar_date_select/locale/ja.js +11 -0
- data/{public → app/assets}/javascripts/calendar_date_select/locale/nl.js +0 -0
- data/{public → app/assets}/javascripts/calendar_date_select/locale/pl.js +0 -0
- data/{public → app/assets}/javascripts/calendar_date_select/locale/pt.js +0 -0
- data/{public → app/assets}/javascripts/calendar_date_select/locale/ru.js +0 -0
- data/{public → app/assets}/javascripts/calendar_date_select/locale/sl.js +0 -0
- data/app/assets/javascripts/calendar_date_select/locale/sv.js +9 -0
- data/{public → app/assets}/stylesheets/calendar_date_select/blue.css +0 -0
- data/{public → app/assets}/stylesheets/calendar_date_select/default.css +0 -0
- data/{public → app/assets}/stylesheets/calendar_date_select/green.css +0 -0
- data/{public → app/assets}/stylesheets/calendar_date_select/plain.css +0 -0
- data/{public → app/assets}/stylesheets/calendar_date_select/red.css +0 -0
- data/{public → app/assets}/stylesheets/calendar_date_select/silver.css +0 -0
- data/{lib → app/helpers}/calendar_date_select/form_helpers.rb +1 -1
- data/{lib → app/helpers}/calendar_date_select/includes_helper.rb +0 -0
- data/calendar_date_select.gemspec +21 -90
- data/lib/calendar_date_select.rb +9 -29
- data/lib/calendar_date_select/calendar_date_select.rb +0 -2
- data/lib/calendar_date_select/version.rb +3 -0
- data/spec/dummy/.gitignore +15 -0
- data/spec/dummy/Gemfile +38 -0
- data/spec/dummy/Gemfile.lock +118 -0
- data/spec/dummy/README.rdoc +261 -0
- data/spec/dummy/Rakefile +7 -0
- data/spec/dummy/app/assets/images/rails.png +0 -0
- data/spec/dummy/app/assets/javascripts/application.js +16 -0
- data/spec/dummy/app/assets/stylesheets/application.css +13 -0
- data/spec/dummy/app/controllers/application_controller.rb +5 -0
- data/spec/dummy/app/helpers/application_helper.rb +2 -0
- data/spec/dummy/app/mailers/.gitkeep +0 -0
- data/spec/dummy/app/models/.gitkeep +0 -0
- data/spec/dummy/app/views/application/example.html.erb +5 -0
- data/spec/dummy/app/views/layouts/application.html.erb +15 -0
- data/spec/dummy/config.ru +4 -0
- data/spec/dummy/config/application.rb +67 -0
- data/spec/dummy/config/boot.rb +6 -0
- data/spec/dummy/config/database.yml +25 -0
- data/spec/dummy/config/environment.rb +5 -0
- data/spec/dummy/config/environments/development.rb +37 -0
- data/spec/dummy/config/environments/production.rb +67 -0
- data/spec/dummy/config/environments/test.rb +37 -0
- data/spec/dummy/config/initializers/backtrace_silencers.rb +7 -0
- data/spec/dummy/config/initializers/inflections.rb +15 -0
- data/spec/dummy/config/initializers/mime_types.rb +5 -0
- data/spec/dummy/config/initializers/secret_token.rb +7 -0
- data/spec/dummy/config/initializers/session_store.rb +8 -0
- data/spec/dummy/config/initializers/wrap_parameters.rb +14 -0
- data/spec/dummy/config/locales/en.yml +5 -0
- data/spec/dummy/config/routes.rb +58 -0
- data/spec/dummy/db/seeds.rb +7 -0
- data/spec/dummy/lib/assets/.gitkeep +0 -0
- data/spec/dummy/lib/tasks/.gitkeep +0 -0
- data/spec/dummy/log/.gitkeep +0 -0
- data/spec/dummy/public/404.html +26 -0
- data/spec/dummy/public/422.html +26 -0
- data/spec/dummy/public/500.html +25 -0
- data/spec/dummy/public/favicon.ico +0 -0
- data/spec/dummy/public/robots.txt +5 -0
- data/spec/dummy/script/rails +6 -0
- data/spec/dummy/test/fixtures/.gitkeep +0 -0
- data/spec/dummy/test/functional/.gitkeep +0 -0
- data/spec/dummy/test/integration/.gitkeep +0 -0
- data/spec/dummy/test/test_helper.rb +13 -0
- data/spec/dummy/test/unit/.gitkeep +0 -0
- data/spec/dummy/vendor/assets/javascripts/.gitkeep +0 -0
- data/spec/dummy/vendor/assets/stylesheets/.gitkeep +0 -0
- data/spec/dummy/vendor/plugins/.gitkeep +0 -0
- data/spec/{calendar_date_select → helpers}/calendar_date_select_spec.rb +0 -0
- data/spec/{calendar_date_select → helpers}/form_helpers_spec.rb +32 -40
- data/spec/helpers/includes_helper_spec.rb +42 -0
- data/spec/spec_helper.rb +8 -24
- metadata +235 -102
- data/Manifest.txt +0 -42
- data/init.rb +0 -1
- data/public/blank_iframe.html +0 -2
- data/spec/calendar_date_select/includes_helper_spec.rb +0 -46
data/Manifest.txt
DELETED
@@ -1,42 +0,0 @@
|
|
1
|
-
History.txt
|
2
|
-
init.rb
|
3
|
-
js_test/functional/cds_test.html
|
4
|
-
js_test/prototype.js
|
5
|
-
js_test/test.css
|
6
|
-
js_test/unit/cds_helper_methods.html
|
7
|
-
js_test/unittest.js
|
8
|
-
lib/calendar_date_select/calendar_date_select.rb
|
9
|
-
lib/calendar_date_select/includes_helper.rb
|
10
|
-
lib/calendar_date_select/form_helpers.rb
|
11
|
-
lib/calendar_date_select.rb
|
12
|
-
Manifest.txt
|
13
|
-
MIT-LICENSE
|
14
|
-
public/blank_iframe.html
|
15
|
-
public/images/calendar_date_select/calendar.gif
|
16
|
-
public/javascripts/calendar_date_select/calendar_date_select.js
|
17
|
-
public/javascripts/calendar_date_select/format_american.js
|
18
|
-
public/javascripts/calendar_date_select/format_db.js
|
19
|
-
public/javascripts/calendar_date_select/format_euro_24hr.js
|
20
|
-
public/javascripts/calendar_date_select/format_euro_24hr_ymd.js
|
21
|
-
public/javascripts/calendar_date_select/format_finnish.js
|
22
|
-
public/javascripts/calendar_date_select/format_hyphen_ampm.js
|
23
|
-
public/javascripts/calendar_date_select/format_iso_date.js
|
24
|
-
public/javascripts/calendar_date_select/format_italian.js
|
25
|
-
public/javascripts/calendar_date_select/locale/de.js
|
26
|
-
public/javascripts/calendar_date_select/locale/fi.js
|
27
|
-
public/javascripts/calendar_date_select/locale/fr.js
|
28
|
-
public/javascripts/calendar_date_select/locale/pl.js
|
29
|
-
public/javascripts/calendar_date_select/locale/pt.js
|
30
|
-
public/javascripts/calendar_date_select/locale/ru.js
|
31
|
-
public/stylesheets/calendar_date_select/blue.css
|
32
|
-
public/stylesheets/calendar_date_select/default.css
|
33
|
-
public/stylesheets/calendar_date_select/plain.css
|
34
|
-
public/stylesheets/calendar_date_select/red.css
|
35
|
-
public/stylesheets/calendar_date_select/silver.css
|
36
|
-
Rakefile
|
37
|
-
README.txt
|
38
|
-
spec/
|
39
|
-
spec/calendar_date_select
|
40
|
-
spec/calendar_date_select/calendar_date_select_spec.rb
|
41
|
-
spec/calendar_date_select/form_helpers_spec.rb
|
42
|
-
spec/spec_helper.rb
|
data/init.rb
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
require File.dirname(__FILE__) + "/lib/calendar_date_select.rb"
|
data/public/blank_iframe.html
DELETED
@@ -1,46 +0,0 @@
|
|
1
|
-
require File.dirname(__FILE__) + '/../spec_helper'
|
2
|
-
|
3
|
-
describe CalendarDateSelect::IncludesHelper do
|
4
|
-
include ActionView::Helpers::TagHelper
|
5
|
-
include ActionView::Helpers::AssetTagHelper
|
6
|
-
include CalendarDateSelect::IncludesHelper
|
7
|
-
|
8
|
-
describe "calendar_date_select_includes" do
|
9
|
-
it "should include the specified locale" do
|
10
|
-
calendar_date_select_includes(:locale => "fr").should include("calendar_date_select/locale/fr.js")
|
11
|
-
end
|
12
|
-
|
13
|
-
it "should include the specified style" do
|
14
|
-
calendar_date_select_includes(:style => "blue").should include("calendar_date_select/blue.css")
|
15
|
-
end
|
16
|
-
|
17
|
-
it "should complain if you provide an illegitimate argument" do
|
18
|
-
lambda { calendar_date_select_includes(:language => "fr") }.should raise_error(ArgumentError)
|
19
|
-
end
|
20
|
-
end
|
21
|
-
|
22
|
-
describe "calendar_date_select_javascripts" do
|
23
|
-
it "should return an array of javascripts" do
|
24
|
-
calendar_date_select_javascripts.should == ["calendar_date_select/calendar_date_select"]
|
25
|
-
end
|
26
|
-
|
27
|
-
it "should return the :javascript_include of the specified format, if the specified format expects it" do
|
28
|
-
CalendarDateSelect.stub!(:format).and_return(CalendarDateSelect::FORMATS[:hyphen_ampm])
|
29
|
-
calendar_date_select_javascripts.should == ["calendar_date_select/calendar_date_select", "calendar_date_select/format_hyphen_ampm"]
|
30
|
-
end
|
31
|
-
|
32
|
-
it "should blow up if an illegitimate argument is passed" do
|
33
|
-
lambda { calendar_date_select_javascripts(:language => "fr") }.should raise_error(ArgumentError)
|
34
|
-
end
|
35
|
-
end
|
36
|
-
|
37
|
-
describe "calendar_date_select_stylesheets" do
|
38
|
-
it "should return an array of stylesheet" do
|
39
|
-
calendar_date_select_javascripts.should == ["calendar_date_select/calendar_date_select"]
|
40
|
-
end
|
41
|
-
|
42
|
-
it "should blow up if an illegitimate argument is passed" do
|
43
|
-
lambda { calendar_date_select_stylesheets(:css_version => "blue") }.should raise_error(ArgumentError)
|
44
|
-
end
|
45
|
-
end
|
46
|
-
end
|