simple-line-icons-rails 0.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,2 @@
1
+ require "simple-line-icons-rails/version"
2
+ require "simple-line-icons-rails/engine" if defined?(::Rails)
@@ -0,0 +1,6 @@
1
+ module SimpleLineIcons
2
+ module Rails
3
+ class Engine < ::Rails::Engine
4
+ end
5
+ end
6
+ end
@@ -0,0 +1,5 @@
1
+ module SimpleLineIcons
2
+ module Rails
3
+ VERSION = "0.0.1"
4
+ end
5
+ end
@@ -0,0 +1 @@
1
+ @import simple-line-icons
@@ -0,0 +1 @@
1
+ @import "simple-line-icons";
@@ -0,0 +1,4 @@
1
+ /*
2
+ *= require simple-line-icons
3
+ */
4
+
@@ -0,0 +1,2 @@
1
+ class PagesController < ActionController::Base
2
+ end
@@ -0,0 +1,4 @@
1
+ # This file is used by Rack-based servers to start the application.
2
+
3
+ require ::File.expand_path('../config/environment', __FILE__)
4
+ run Dummy::Application
@@ -0,0 +1,18 @@
1
+ require File.expand_path('../boot', __FILE__)
2
+
3
+ # require "rails/all"
4
+ require "sprockets/railtie"
5
+
6
+ Bundler.require(:default, :development)
7
+
8
+ module Dummy
9
+ class Application < Rails::Application
10
+ config.encoding = "utf-8"
11
+ config.assets.enabled = true
12
+ config.assets.version = '1.0'
13
+
14
+ # replacement for environments/*.rb
15
+ config.active_support.deprecation = :stderr
16
+ config.eager_load = false
17
+ end
18
+ end
@@ -0,0 +1,10 @@
1
+ require 'rubygems'
2
+ gemfile = File.expand_path('../../../../Gemfile', __FILE__)
3
+
4
+ if File.exist?(gemfile)
5
+ ENV['BUNDLE_GEMFILE'] = gemfile
6
+ require 'bundler'
7
+ Bundler.setup
8
+ end
9
+
10
+ $:.unshift File.expand_path('../../../../lib', __FILE__)
@@ -0,0 +1,5 @@
1
+ # Load the rails application
2
+ require File.expand_path('../application', __FILE__)
3
+
4
+ # Initialize the rails application
5
+ Dummy::Application.initialize!
@@ -0,0 +1,8 @@
1
+ # Be sure to restart your server when you modify this file.
2
+
3
+ # Your secret key for verifying the integrity of signed cookies.
4
+ # If you change this key, all old signed cookies will become invalid!
5
+ # Make sure the secret is at least 30 characters and all random,
6
+ # no regular words or you'll be exposed to dictionary attacks.
7
+ Dummy::Application.config.secret_token = 'deadbeefdeadbeefdeadbeefdeadbeefdeadbeefdeadbeefdeadbeefdeadbeefdeadbeefdeadbeefdeadbeefdeadbeefdeadbeefdeadbeefdeadbeefdeadbeef'
8
+ Dummy::Application.config.secret_key_base = 'deadbeef' if Dummy::Application.config.respond_to?(:secret_key_base)
@@ -0,0 +1,3 @@
1
+ Dummy::Application.routes.draw do
2
+ get "/icons", :to => "pages#icons"
3
+ end
@@ -0,0 +1,70 @@
1
+ -----------------------------------------------
2
+ SimpleLineIconsRailsTest: test_engine_is_loaded
3
+ -----------------------------------------------
4
+ -----------------------------------------------
5
+ SimpleLineIconsRailsTest: test_fonts_are_served
6
+ -----------------------------------------------
7
+ Started GET "/assets/Simple-Line-Icons.eot" for 127.0.0.1 at 2014-09-24 00:30:56 +0800
8
+ Started GET "/assets/Simple-Line-Icons.ttf" for 127.0.0.1 at 2014-09-24 00:30:56 +0800
9
+ Started GET "/assets/Simple-Line-Icons.woff" for 127.0.0.1 at 2014-09-24 00:30:56 +0800
10
+ ----------------------------------------------------------------------
11
+ SimpleLineIconsRailsTest: test_helpers_should_be_available_in_the_view
12
+ ----------------------------------------------------------------------
13
+ Started GET "/icons" for 127.0.0.1 at 2014-09-24 00:30:56 +0800
14
+ Processing by PagesController#icons as HTML
15
+ Completed 200 OK in 6ms (Views: 6.4ms)
16
+ ---------------------------------------------------------------------------------
17
+ SimpleLineIconsRailsTest: test_stylesheet_is_available_in_a_css_sprockets_require
18
+ ---------------------------------------------------------------------------------
19
+ Started GET "/assets/sprockets-require.css" for 127.0.0.1 at 2014-09-24 00:30:56 +0800
20
+ -----------------------------------------------------------------------
21
+ SimpleLineIconsRailsTest: test_stylesheet_is_available_in_a_sass_import
22
+ -----------------------------------------------------------------------
23
+ Started GET "/assets/sass-import.css" for 127.0.0.1 at 2014-09-24 00:30:56 +0800
24
+ -----------------------------------------------------------------------
25
+ SimpleLineIconsRailsTest: test_stylesheet_is_available_in_a_scss_import
26
+ -----------------------------------------------------------------------
27
+ Started GET "/assets/scss-import.css" for 127.0.0.1 at 2014-09-24 00:30:57 +0800
28
+ -----------------------------------------------------
29
+ SimpleLineIconsRailsTest: test_stylesheets_are_served
30
+ -----------------------------------------------------
31
+ Started GET "/assets/simple-line-icons.css" for 127.0.0.1 at 2014-09-24 00:30:57 +0800
32
+ -------------------------------------------------------------------------------------
33
+ SimpleLineIconsRailsTest: test_stylesheets_contain_asset_pipeline_references_to_fonts
34
+ -------------------------------------------------------------------------------------
35
+ Started GET "/assets/simple-line-icons.css" for 127.0.0.1 at 2014-09-24 00:30:57 +0800
36
+ -----------------------------------------------
37
+ SimpleLineIconsRailsTest: test_engine_is_loaded
38
+ -----------------------------------------------
39
+ -----------------------------------------------
40
+ SimpleLineIconsRailsTest: test_fonts_are_served
41
+ -----------------------------------------------
42
+ Started GET "/assets/Simple-Line-Icons.eot" for 127.0.0.1 at 2014-09-24 00:31:50 +0800
43
+ Started GET "/assets/Simple-Line-Icons.ttf" for 127.0.0.1 at 2014-09-24 00:31:50 +0800
44
+ Started GET "/assets/Simple-Line-Icons.woff" for 127.0.0.1 at 2014-09-24 00:31:50 +0800
45
+ ----------------------------------------------------------------------
46
+ SimpleLineIconsRailsTest: test_helpers_should_be_available_in_the_view
47
+ ----------------------------------------------------------------------
48
+ Started GET "/icons" for 127.0.0.1 at 2014-09-24 00:31:50 +0800
49
+ Processing by PagesController#icons as HTML
50
+ Completed 200 OK in 6ms (Views: 6.0ms)
51
+ ---------------------------------------------------------------------------------
52
+ SimpleLineIconsRailsTest: test_stylesheet_is_available_in_a_css_sprockets_require
53
+ ---------------------------------------------------------------------------------
54
+ Started GET "/assets/sprockets-require.css" for 127.0.0.1 at 2014-09-24 00:31:50 +0800
55
+ -----------------------------------------------------------------------
56
+ SimpleLineIconsRailsTest: test_stylesheet_is_available_in_a_sass_import
57
+ -----------------------------------------------------------------------
58
+ Started GET "/assets/sass-import.css" for 127.0.0.1 at 2014-09-24 00:31:50 +0800
59
+ -----------------------------------------------------------------------
60
+ SimpleLineIconsRailsTest: test_stylesheet_is_available_in_a_scss_import
61
+ -----------------------------------------------------------------------
62
+ Started GET "/assets/scss-import.css" for 127.0.0.1 at 2014-09-24 00:31:50 +0800
63
+ -----------------------------------------------------
64
+ SimpleLineIconsRailsTest: test_stylesheets_are_served
65
+ -----------------------------------------------------
66
+ Started GET "/assets/simple-line-icons.css" for 127.0.0.1 at 2014-09-24 00:31:50 +0800
67
+ -------------------------------------------------------------------------------------
68
+ SimpleLineIconsRailsTest: test_stylesheets_contain_asset_pipeline_references_to_fonts
69
+ -------------------------------------------------------------------------------------
70
+ Started GET "/assets/simple-line-icons.css" for 127.0.0.1 at 2014-09-24 00:31:50 +0800
@@ -0,0 +1,63 @@
1
+ require 'test_helper'
2
+
3
+ class SimpleLineIconsRailsTest < ActionDispatch::IntegrationTest
4
+ teardown { clean_sprockets_cache }
5
+
6
+ test "engine is loaded" do
7
+ assert_equal ::Rails::Engine, SimpleLineIcons::Rails::Engine.superclass
8
+ end
9
+
10
+ test "fonts are served" do
11
+ get "/assets/Simple-Line-Icons.eot"
12
+ assert_response :success
13
+ get "/assets/Simple-Line-Icons.ttf"
14
+ assert_response :success
15
+ get "/assets/Simple-Line-Icons.woff"
16
+ assert_response :success
17
+ end
18
+
19
+ test "stylesheets are served" do
20
+ get "/assets/simple-line-icons.css"
21
+ assert_simple_line_icons(response)
22
+ end
23
+
24
+ test "stylesheets contain asset pipeline references to fonts" do
25
+ get "/assets/simple-line-icons.css"
26
+ assert_match "/assets/Simple-Line-Icons.eot", response.body
27
+ assert_match "/assets/Simple-Line-Icons.eot?#iefix", response.body
28
+ assert_match "/assets/Simple-Line-Icons.woff", response.body
29
+ assert_match "/assets/Simple-Line-Icons.ttf", response.body
30
+ assert_match "/assets/Simple-Line-Icons.svg#Simple-Line-Icons", response.body
31
+ end
32
+
33
+ test "stylesheet is available in a css sprockets require" do
34
+ get "/assets/sprockets-require.css"
35
+ assert_simple_line_icons(response)
36
+ end
37
+
38
+ test "stylesheet is available in a sass import" do
39
+ get "/assets/sass-import.css"
40
+ assert_simple_line_icons(response)
41
+ end
42
+
43
+ test "stylesheet is available in a scss import" do
44
+ get "/assets/scss-import.css"
45
+ assert_simple_line_icons(response)
46
+ end
47
+
48
+ test "helpers should be available in the view" do
49
+ get "/icons"
50
+ assert_response :success
51
+ end
52
+
53
+ private
54
+
55
+ def clean_sprockets_cache
56
+ FileUtils.rm_rf File.expand_path("../dummy/tmp", __FILE__)
57
+ end
58
+
59
+ def assert_simple_line_icons(response)
60
+ assert_response :success
61
+ assert_match(/font-family:\s*'Simple-Line-Icons';/, response.body)
62
+ end
63
+ end
@@ -0,0 +1,7 @@
1
+ # Configure Rails Environment
2
+ ENV["RAILS_ENV"] = "test"
3
+
4
+ require File.expand_path("../dummy/config/environment.rb", __FILE__)
5
+ require "rails/test_help"
6
+
7
+ Rails.backtrace_cleaner.remove_silencers!
metadata ADDED
@@ -0,0 +1,132 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: simple-line-icons-rails
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.0.1
5
+ platform: ruby
6
+ authors:
7
+ - JeskTop
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2014-11-18 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: railties
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - ">="
18
+ - !ruby/object:Gem::Version
19
+ version: '3.2'
20
+ - - "<"
21
+ - !ruby/object:Gem::Version
22
+ version: '5.0'
23
+ type: :runtime
24
+ prerelease: false
25
+ version_requirements: !ruby/object:Gem::Requirement
26
+ requirements:
27
+ - - ">="
28
+ - !ruby/object:Gem::Version
29
+ version: '3.2'
30
+ - - "<"
31
+ - !ruby/object:Gem::Version
32
+ version: '5.0'
33
+ - !ruby/object:Gem::Dependency
34
+ name: activesupport
35
+ requirement: !ruby/object:Gem::Requirement
36
+ requirements:
37
+ - - ">="
38
+ - !ruby/object:Gem::Version
39
+ version: '0'
40
+ type: :development
41
+ prerelease: false
42
+ version_requirements: !ruby/object:Gem::Requirement
43
+ requirements:
44
+ - - ">="
45
+ - !ruby/object:Gem::Version
46
+ version: '0'
47
+ - !ruby/object:Gem::Dependency
48
+ name: sass-rails
49
+ requirement: !ruby/object:Gem::Requirement
50
+ requirements:
51
+ - - ">="
52
+ - !ruby/object:Gem::Version
53
+ version: '0'
54
+ type: :development
55
+ prerelease: false
56
+ version_requirements: !ruby/object:Gem::Requirement
57
+ requirements:
58
+ - - ">="
59
+ - !ruby/object:Gem::Version
60
+ version: '0'
61
+ description: an asset gemification of the simple-line-icons icon font library
62
+ email:
63
+ - frayay@gmail.com
64
+ executables: []
65
+ extensions: []
66
+ extra_rdoc_files: []
67
+ files:
68
+ - LICENSE.txt
69
+ - README.md
70
+ - Rakefile
71
+ - app/assets/fonts/Simple-Line-Icons.eot
72
+ - app/assets/fonts/Simple-Line-Icons.svg
73
+ - app/assets/fonts/Simple-Line-Icons.ttf
74
+ - app/assets/fonts/Simple-Line-Icons.woff
75
+ - app/assets/stylesheets/simple-line-icons.css.erb
76
+ - lib/simple-line-icons-rails.rb
77
+ - lib/simple-line-icons-rails/engine.rb
78
+ - lib/simple-line-icons-rails/version.rb
79
+ - test/dummy/app/assets/stylesheets/sass-import.css.sass
80
+ - test/dummy/app/assets/stylesheets/scss-import.css.scss
81
+ - test/dummy/app/assets/stylesheets/sprockets-require.css
82
+ - test/dummy/app/controllers/pages_controller.rb
83
+ - test/dummy/app/views/pages/icons.html.erb
84
+ - test/dummy/config.ru
85
+ - test/dummy/config/application.rb
86
+ - test/dummy/config/boot.rb
87
+ - test/dummy/config/environment.rb
88
+ - test/dummy/config/initializers/secret_token.rb
89
+ - test/dummy/config/routes.rb
90
+ - test/dummy/log/test.log
91
+ - test/simple_line_icons_rails_test.rb
92
+ - test/test_helper.rb
93
+ homepage: https://github.com/minnowlab/simple-line-icons-rails/
94
+ licenses:
95
+ - MIT
96
+ metadata: {}
97
+ post_install_message:
98
+ rdoc_options: []
99
+ require_paths:
100
+ - lib
101
+ required_ruby_version: !ruby/object:Gem::Requirement
102
+ requirements:
103
+ - - ">="
104
+ - !ruby/object:Gem::Version
105
+ version: '0'
106
+ required_rubygems_version: !ruby/object:Gem::Requirement
107
+ requirements:
108
+ - - ">="
109
+ - !ruby/object:Gem::Version
110
+ version: '0'
111
+ requirements: []
112
+ rubyforge_project:
113
+ rubygems_version: 2.4.4
114
+ signing_key:
115
+ specification_version: 4
116
+ summary: I like simple-line-icons. I like the asset pipeline. I like semantic versioning.
117
+ If you do too, you're welcome.
118
+ test_files:
119
+ - test/dummy/app/assets/stylesheets/sass-import.css.sass
120
+ - test/dummy/app/assets/stylesheets/scss-import.css.scss
121
+ - test/dummy/app/assets/stylesheets/sprockets-require.css
122
+ - test/dummy/app/controllers/pages_controller.rb
123
+ - test/dummy/app/views/pages/icons.html.erb
124
+ - test/dummy/config/application.rb
125
+ - test/dummy/config/boot.rb
126
+ - test/dummy/config/environment.rb
127
+ - test/dummy/config/initializers/secret_token.rb
128
+ - test/dummy/config/routes.rb
129
+ - test/dummy/config.ru
130
+ - test/dummy/log/test.log
131
+ - test/simple_line_icons_rails_test.rb
132
+ - test/test_helper.rb