liszt 0.0.1 → 0.0.3

Sign up to get free protection for your applications and to get access to all the features.
Files changed (86) hide show
  1. data/.gitignore +7 -3
  2. data/Gemfile +1 -0
  3. data/Gemfile.lock +9 -2
  4. data/Gemfile.rails2 +8 -0
  5. data/Gemfile.rails2.lock +45 -0
  6. data/Rakefile +32 -1
  7. data/lib/liszt/{list.rb → redis_list.rb} +12 -7
  8. data/lib/liszt/version.rb +1 -1
  9. data/lib/liszt.rb +28 -8
  10. data/test/dummy_2.3/Rakefile +10 -0
  11. data/test/dummy_2.3/app/controllers/application_controller.rb +10 -0
  12. data/test/dummy_2.3/app/models/group.rb +2 -0
  13. data/test/dummy_2.3/app/models/person.rb +3 -0
  14. data/test/dummy_2.3/config/boot.rb +114 -0
  15. data/test/dummy_2.3/config/database.yml +22 -0
  16. data/test/dummy_2.3/config/environment.rb +43 -0
  17. data/test/dummy_2.3/config/environments/development.rb +17 -0
  18. data/test/dummy_2.3/config/environments/test.rb +28 -0
  19. data/test/dummy_2.3/config/initializers/backtrace_silencers.rb +7 -0
  20. data/test/dummy_2.3/config/initializers/bundler.rb +4 -0
  21. data/test/dummy_2.3/config/initializers/cookie_verification_secret.rb +7 -0
  22. data/test/dummy_2.3/config/initializers/inflections.rb +10 -0
  23. data/test/{dummy → dummy_2.3}/config/initializers/mime_types.rb +0 -0
  24. data/test/dummy_2.3/config/initializers/new_rails_defaults.rb +21 -0
  25. data/test/dummy_2.3/config/initializers/session_store.rb +15 -0
  26. data/test/dummy_2.3/config/locales/en.yml +5 -0
  27. data/test/dummy_2.3/config/routes.rb +43 -0
  28. data/test/dummy_2.3/db/migrate/20110922194432_create_people.rb +15 -0
  29. data/test/dummy_2.3/db/migrate/20110922194512_create_groups.rb +12 -0
  30. data/test/dummy_2.3/db/schema.rb +27 -0
  31. data/test/dummy_2.3/db/seeds.rb +7 -0
  32. data/test/dummy_2.3/script/about +4 -0
  33. data/test/dummy_2.3/script/console +3 -0
  34. data/test/dummy_2.3/script/dbconsole +3 -0
  35. data/test/dummy_2.3/script/destroy +3 -0
  36. data/test/dummy_2.3/script/generate +3 -0
  37. data/test/dummy_2.3/script/performance/benchmarker +3 -0
  38. data/test/dummy_2.3/script/performance/profiler +3 -0
  39. data/test/dummy_2.3/script/plugin +3 -0
  40. data/test/dummy_2.3/script/runner +3 -0
  41. data/test/dummy_2.3/script/server +3 -0
  42. data/test/dummy_2.3/test/fixtures/groups.yml +12 -0
  43. data/test/dummy_2.3/test/fixtures/people.yml +59 -0
  44. data/test/{dummy → dummy_3.1}/Rakefile +0 -0
  45. data/test/{dummy → dummy_3.1}/app/controllers/application_controller.rb +0 -0
  46. data/test/{dummy/app/mailers → dummy_3.1/app/models}/.gitkeep +0 -0
  47. data/test/dummy_3.1/app/models/group.rb +2 -0
  48. data/test/dummy_3.1/app/models/person.rb +3 -0
  49. data/test/{dummy → dummy_3.1}/config/application.rb +3 -0
  50. data/test/{dummy → dummy_3.1}/config/boot.rb +0 -0
  51. data/test/{dummy → dummy_3.1}/config/database.yml +0 -0
  52. data/test/{dummy → dummy_3.1}/config/environment.rb +0 -0
  53. data/test/{dummy → dummy_3.1}/config/environments/development.rb +0 -0
  54. data/test/{dummy → dummy_3.1}/config/environments/test.rb +0 -0
  55. data/test/{dummy → dummy_3.1}/config/initializers/backtrace_silencers.rb +0 -0
  56. data/test/{dummy → dummy_3.1}/config/initializers/inflections.rb +0 -0
  57. data/test/dummy_3.1/config/initializers/mime_types.rb +5 -0
  58. data/test/{dummy → dummy_3.1}/config/initializers/secret_token.rb +0 -0
  59. data/test/{dummy → dummy_3.1}/config/initializers/session_store.rb +0 -0
  60. data/test/{dummy → dummy_3.1}/config/initializers/wrap_parameters.rb +0 -0
  61. data/test/{dummy → dummy_3.1}/config/locales/en.yml +0 -0
  62. data/test/{dummy → dummy_3.1}/config/routes.rb +0 -0
  63. data/test/{dummy → dummy_3.1}/config.ru +0 -0
  64. data/test/dummy_3.1/db/migrate/20110922194058_create_people.rb +11 -0
  65. data/test/dummy_3.1/db/migrate/20110922194126_create_groups.rb +8 -0
  66. data/test/dummy_3.1/db/schema.rb +29 -0
  67. data/test/{dummy/app/models → dummy_3.1/lib/assets}/.gitkeep +0 -0
  68. data/test/{dummy/lib/assets → dummy_3.1/log}/.gitkeep +0 -0
  69. data/test/{dummy → dummy_3.1}/script/rails +0 -0
  70. data/test/dummy_3.1/test/fixtures/groups.yml +12 -0
  71. data/test/dummy_3.1/test/fixtures/people.yml +59 -0
  72. data/test/liszt_test.rb +118 -2
  73. data/test/redis.conf +2 -0
  74. data/test/redis_list_test.rb +168 -0
  75. data/test/test_helper.rb +39 -2
  76. metadata +141 -73
  77. data/test/dummy/app/assets/javascripts/application.js +0 -7
  78. data/test/dummy/app/assets/stylesheets/application.css +0 -7
  79. data/test/dummy/app/helpers/application_helper.rb +0 -2
  80. data/test/dummy/app/views/layouts/application.html.erb +0 -14
  81. data/test/dummy/config/environments/production.rb +0 -51
  82. data/test/dummy/log/.gitkeep +0 -0
  83. data/test/dummy/public/404.html +0 -26
  84. data/test/dummy/public/422.html +0 -26
  85. data/test/dummy/public/500.html +0 -26
  86. data/test/dummy/public/favicon.ico +0 -0
@@ -0,0 +1,168 @@
1
+ require 'test_helper'
2
+
3
+ class RedisListTest < ActiveSupport::TestCase
4
+ context "the Redis list wrapper" do
5
+ setup do
6
+ Liszt.redis.flushall
7
+ @list = Liszt::RedisList.new('liszt:test')
8
+ end
9
+
10
+ should "clear and populate successfully" do
11
+ @list.clear_and_populate!([1,2,3])
12
+ @list.clear_and_populate!([4,5,6])
13
+ assert_equal @list.to_a, [4,5,6]
14
+ end
15
+
16
+ should "not be initialized before it's initialized" do
17
+ assert !@list.initialized?
18
+ end
19
+
20
+ should "be initialized once it's initialized" do
21
+ @list.clear_and_populate!([1])
22
+ assert @list.initialized?
23
+ end
24
+
25
+ context "given a list with some ids" do
26
+ setup do
27
+ @list.clear_and_populate!([1,5,4,2])
28
+ end
29
+
30
+ should "know if the list includes an id" do
31
+ assert @list.include?(4)
32
+ assert !@list.include?(3)
33
+ end
34
+
35
+ should "know the index of an id" do
36
+ assert_equal @list.index(1), 0
37
+ assert_equal @list.index(4), 2
38
+ assert_equal @list.index(2), 3
39
+ end
40
+
41
+ should "unshift onto the front of the list" do
42
+ @list.unshift(8)
43
+ assert_equal @list.to_a, [8,1,5,4,2]
44
+ end
45
+
46
+ should "not unshift if already present" do
47
+ @list.unshift(5)
48
+ assert_equal @list.to_a, [1,5,4,2]
49
+ end
50
+
51
+ should "unshift! if already present" do
52
+ @list.unshift!(5)
53
+ assert_equal @list.to_a, [5,1,5,4,2]
54
+ end
55
+
56
+ should "push onto the end of the list" do
57
+ @list.push(8)
58
+ assert_equal @list.to_a, [1,5,4,2,8]
59
+ end
60
+
61
+ should "not push if already present" do
62
+ @list.push(5)
63
+ assert_equal @list.to_a, [1,5,4,2]
64
+ end
65
+
66
+ should "push! if already present" do
67
+ @list.push!(5)
68
+ assert_equal @list.to_a, [1,5,4,2,5]
69
+ end
70
+
71
+ should "remove an id" do
72
+ @list.remove(5)
73
+ assert_equal @list.to_a, [1,4,2]
74
+ end
75
+
76
+ should "clear all ids without un-initializing" do
77
+ @list.clear
78
+ assert @list.initialized?
79
+ assert_equal @list.to_a, []
80
+ end
81
+
82
+ should "know the length of the list" do
83
+ assert_equal @list.length, 4
84
+ end
85
+
86
+ should "return nil for length if uninitialized" do
87
+ @list.uninitialize
88
+ assert_nil @list.length
89
+ end
90
+
91
+ should "return all ids (and no marker) for .all/.to_a" do
92
+ assert_equal @list.all, [1,5,4,2]
93
+ end
94
+
95
+ should "move an id down from the top" do
96
+ @list.move_down(1)
97
+ assert_equal @list.to_a, [5,1,4,2]
98
+ end
99
+
100
+ should "move an id down from the middle" do
101
+ @list.move_down(4)
102
+ assert_equal @list.to_a, [1,5,2,4]
103
+ end
104
+
105
+ should "not move an id down from the bottom" do
106
+ @list.move_down(2)
107
+ assert_equal @list.to_a, [1,5,4,2]
108
+ end
109
+
110
+ should "not move an id up from the top" do
111
+ @list.move_up(1)
112
+ assert_equal @list.to_a, [1,5,4,2]
113
+ end
114
+
115
+ should "move an id up from the middle" do
116
+ @list.move_up(4)
117
+ assert_equal @list.to_a, [1,4,5,2]
118
+ end
119
+
120
+ should "move an id up from the bottom" do
121
+ @list.move_up(2)
122
+ assert_equal @list.to_a, [1,5,2,4]
123
+ end
124
+
125
+ should "not move an id to the top from the top" do
126
+ @list.move_to_top(1)
127
+ assert_equal @list.to_a, [1,5,4,2]
128
+ end
129
+
130
+ should "move an id to the top" do
131
+ @list.move_to_top(4)
132
+ assert_equal @list.to_a, [4,1,5,2]
133
+ end
134
+
135
+ should "move an id to the bottom" do
136
+ @list.move_to_bottom(4)
137
+ assert_equal @list.to_a, [1,5,2,4]
138
+ end
139
+
140
+ should "not move an id to the bottom from the bottom" do
141
+ @list.move_to_bottom(2)
142
+ assert_equal @list.to_a, [1,5,4,2]
143
+ end
144
+ end
145
+
146
+ context "locking mechanism" do
147
+ should "get an exclusive lock" do
148
+ assert @list.send(:get_lock)
149
+ assert !@list.send(:get_lock)
150
+ @list.send(:release_lock)
151
+ end
152
+
153
+ should "release the lock" do
154
+ @list.send(:get_lock)
155
+ @list.send(:release_lock)
156
+ assert @list.send(:get_lock)
157
+ @list.send(:release_lock)
158
+ end
159
+
160
+ should "time out the lock" do
161
+ @list.send(:get_lock, 0)
162
+ sleep(0.5)
163
+ assert @list.send(:get_lock)
164
+ end
165
+ end
166
+ end
167
+ end
168
+
data/test/test_helper.rb CHANGED
@@ -1,8 +1,45 @@
1
1
  # Configure Rails Environment
2
2
  ENV["RAILS_ENV"] = "test"
3
3
 
4
- require File.expand_path("../dummy/config/environment.rb", __FILE__)
5
- require "rails/test_help"
4
+ if ENV["BUNDLE_GEMFILE"] =~ /rails2/
5
+ require File.expand_path("../dummy_2.3/config/environment.rb", __FILE__)
6
+ require 'test_help'
7
+ else
8
+ require File.expand_path("../dummy_3.1/config/environment.rb", __FILE__)
9
+ require "rails/test_help"
10
+ end
11
+
12
+ if ENV["DEBUG_REDIS"] =~ /y/
13
+ class Redis
14
+ module Connection
15
+ class Ruby
16
+ def write(command)
17
+ $stderr.puts "\n<- #{command}"
18
+ @sock.write(build_command(command))
19
+ end
20
+
21
+ def format_reply(reply_type, line)
22
+ reply = case reply_type
23
+ when MINUS then format_error_reply(line)
24
+ when PLUS then format_status_reply(line)
25
+ when COLON then format_integer_reply(line)
26
+ when DOLLAR then format_bulk_reply(line)
27
+ when ASTERISK then format_multi_bulk_reply(line)
28
+ else raise ProtocolError.new(reply_type)
29
+ end
30
+ $stderr.puts "-> #{reply}"
31
+ reply
32
+ end
33
+ end
34
+ end
35
+ end
36
+ end
37
+
38
+ class Array
39
+ def swap(i1, i2)
40
+ self[i1], self[i2] = self[i2], self[i1]
41
+ end
42
+ end
6
43
 
7
44
  Rails.backtrace_cleaner.remove_silencers!
8
45
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: liszt
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.0.3
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,11 +9,11 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2011-09-22 00:00:00.000000000Z
12
+ date: 2011-09-23 00:00:00.000000000Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: rails
16
- requirement: &70276151086120 !ruby/object:Gem::Requirement
16
+ requirement: &70260000385480 !ruby/object:Gem::Requirement
17
17
  none: false
18
18
  requirements:
19
19
  - - ! '>='
@@ -21,10 +21,10 @@ dependencies:
21
21
  version: 2.3.2
22
22
  type: :runtime
23
23
  prerelease: false
24
- version_requirements: *70276151086120
24
+ version_requirements: *70260000385480
25
25
  - !ruby/object:Gem::Dependency
26
26
  name: redis
27
- requirement: &70276151085700 !ruby/object:Gem::Requirement
27
+ requirement: &70260000385060 !ruby/object:Gem::Requirement
28
28
  none: false
29
29
  requirements:
30
30
  - - ! '>='
@@ -32,10 +32,10 @@ dependencies:
32
32
  version: '0'
33
33
  type: :runtime
34
34
  prerelease: false
35
- version_requirements: *70276151085700
35
+ version_requirements: *70260000385060
36
36
  - !ruby/object:Gem::Dependency
37
37
  name: yard
38
- requirement: &70276151085240 !ruby/object:Gem::Requirement
38
+ requirement: &70260000384600 !ruby/object:Gem::Requirement
39
39
  none: false
40
40
  requirements:
41
41
  - - ! '>='
@@ -43,10 +43,10 @@ dependencies:
43
43
  version: '0'
44
44
  type: :development
45
45
  prerelease: false
46
- version_requirements: *70276151085240
46
+ version_requirements: *70260000384600
47
47
  - !ruby/object:Gem::Dependency
48
48
  name: rdiscount
49
- requirement: &70276151084820 !ruby/object:Gem::Requirement
49
+ requirement: &70260000384180 !ruby/object:Gem::Requirement
50
50
  none: false
51
51
  requirements:
52
52
  - - ! '>='
@@ -54,7 +54,7 @@ dependencies:
54
54
  version: '0'
55
55
  type: :development
56
56
  prerelease: false
57
- version_requirements: *70276151084820
57
+ version_requirements: *70260000384180
58
58
  description: Liszt is an alternative to acts_as_list and sortable that uses atomic
59
59
  Redis operations to maintain scoped ordering information for ActiveRecord objects.
60
60
  email:
@@ -67,45 +67,80 @@ files:
67
67
  - .yardopts
68
68
  - Gemfile
69
69
  - Gemfile.lock
70
+ - Gemfile.rails2
71
+ - Gemfile.rails2.lock
70
72
  - LICENSE
71
73
  - Rakefile
72
74
  - lib/liszt.rb
73
75
  - lib/liszt/instantizeable.rb
74
- - lib/liszt/list.rb
76
+ - lib/liszt/redis_list.rb
75
77
  - lib/liszt/version.rb
76
78
  - liszt.gemspec
77
- - test/dummy/Rakefile
78
- - test/dummy/app/assets/javascripts/application.js
79
- - test/dummy/app/assets/stylesheets/application.css
80
- - test/dummy/app/controllers/application_controller.rb
81
- - test/dummy/app/helpers/application_helper.rb
82
- - test/dummy/app/mailers/.gitkeep
83
- - test/dummy/app/models/.gitkeep
84
- - test/dummy/app/views/layouts/application.html.erb
85
- - test/dummy/config.ru
86
- - test/dummy/config/application.rb
87
- - test/dummy/config/boot.rb
88
- - test/dummy/config/database.yml
89
- - test/dummy/config/environment.rb
90
- - test/dummy/config/environments/development.rb
91
- - test/dummy/config/environments/production.rb
92
- - test/dummy/config/environments/test.rb
93
- - test/dummy/config/initializers/backtrace_silencers.rb
94
- - test/dummy/config/initializers/inflections.rb
95
- - test/dummy/config/initializers/mime_types.rb
96
- - test/dummy/config/initializers/secret_token.rb
97
- - test/dummy/config/initializers/session_store.rb
98
- - test/dummy/config/initializers/wrap_parameters.rb
99
- - test/dummy/config/locales/en.yml
100
- - test/dummy/config/routes.rb
101
- - test/dummy/lib/assets/.gitkeep
102
- - test/dummy/log/.gitkeep
103
- - test/dummy/public/404.html
104
- - test/dummy/public/422.html
105
- - test/dummy/public/500.html
106
- - test/dummy/public/favicon.ico
107
- - test/dummy/script/rails
79
+ - test/dummy_2.3/Rakefile
80
+ - test/dummy_2.3/app/controllers/application_controller.rb
81
+ - test/dummy_2.3/app/models/group.rb
82
+ - test/dummy_2.3/app/models/person.rb
83
+ - test/dummy_2.3/config/boot.rb
84
+ - test/dummy_2.3/config/database.yml
85
+ - test/dummy_2.3/config/environment.rb
86
+ - test/dummy_2.3/config/environments/development.rb
87
+ - test/dummy_2.3/config/environments/test.rb
88
+ - test/dummy_2.3/config/initializers/backtrace_silencers.rb
89
+ - test/dummy_2.3/config/initializers/bundler.rb
90
+ - test/dummy_2.3/config/initializers/cookie_verification_secret.rb
91
+ - test/dummy_2.3/config/initializers/inflections.rb
92
+ - test/dummy_2.3/config/initializers/mime_types.rb
93
+ - test/dummy_2.3/config/initializers/new_rails_defaults.rb
94
+ - test/dummy_2.3/config/initializers/session_store.rb
95
+ - test/dummy_2.3/config/locales/en.yml
96
+ - test/dummy_2.3/config/routes.rb
97
+ - test/dummy_2.3/db/migrate/20110922194432_create_people.rb
98
+ - test/dummy_2.3/db/migrate/20110922194512_create_groups.rb
99
+ - test/dummy_2.3/db/schema.rb
100
+ - test/dummy_2.3/db/seeds.rb
101
+ - test/dummy_2.3/script/about
102
+ - test/dummy_2.3/script/console
103
+ - test/dummy_2.3/script/dbconsole
104
+ - test/dummy_2.3/script/destroy
105
+ - test/dummy_2.3/script/generate
106
+ - test/dummy_2.3/script/performance/benchmarker
107
+ - test/dummy_2.3/script/performance/profiler
108
+ - test/dummy_2.3/script/plugin
109
+ - test/dummy_2.3/script/runner
110
+ - test/dummy_2.3/script/server
111
+ - test/dummy_2.3/test/fixtures/groups.yml
112
+ - test/dummy_2.3/test/fixtures/people.yml
113
+ - test/dummy_3.1/Rakefile
114
+ - test/dummy_3.1/app/controllers/application_controller.rb
115
+ - test/dummy_3.1/app/models/.gitkeep
116
+ - test/dummy_3.1/app/models/group.rb
117
+ - test/dummy_3.1/app/models/person.rb
118
+ - test/dummy_3.1/config.ru
119
+ - test/dummy_3.1/config/application.rb
120
+ - test/dummy_3.1/config/boot.rb
121
+ - test/dummy_3.1/config/database.yml
122
+ - test/dummy_3.1/config/environment.rb
123
+ - test/dummy_3.1/config/environments/development.rb
124
+ - test/dummy_3.1/config/environments/test.rb
125
+ - test/dummy_3.1/config/initializers/backtrace_silencers.rb
126
+ - test/dummy_3.1/config/initializers/inflections.rb
127
+ - test/dummy_3.1/config/initializers/mime_types.rb
128
+ - test/dummy_3.1/config/initializers/secret_token.rb
129
+ - test/dummy_3.1/config/initializers/session_store.rb
130
+ - test/dummy_3.1/config/initializers/wrap_parameters.rb
131
+ - test/dummy_3.1/config/locales/en.yml
132
+ - test/dummy_3.1/config/routes.rb
133
+ - test/dummy_3.1/db/migrate/20110922194058_create_people.rb
134
+ - test/dummy_3.1/db/migrate/20110922194126_create_groups.rb
135
+ - test/dummy_3.1/db/schema.rb
136
+ - test/dummy_3.1/lib/assets/.gitkeep
137
+ - test/dummy_3.1/log/.gitkeep
138
+ - test/dummy_3.1/script/rails
139
+ - test/dummy_3.1/test/fixtures/groups.yml
140
+ - test/dummy_3.1/test/fixtures/people.yml
108
141
  - test/liszt_test.rb
142
+ - test/redis.conf
143
+ - test/redis_list_test.rb
109
144
  - test/test_helper.rb
110
145
  homepage: http://academia.edu
111
146
  licenses: []
@@ -132,36 +167,69 @@ signing_key:
132
167
  specification_version: 3
133
168
  summary: ActiveRecord sorting using Redis lists
134
169
  test_files:
135
- - test/dummy/Rakefile
136
- - test/dummy/app/assets/javascripts/application.js
137
- - test/dummy/app/assets/stylesheets/application.css
138
- - test/dummy/app/controllers/application_controller.rb
139
- - test/dummy/app/helpers/application_helper.rb
140
- - test/dummy/app/mailers/.gitkeep
141
- - test/dummy/app/models/.gitkeep
142
- - test/dummy/app/views/layouts/application.html.erb
143
- - test/dummy/config.ru
144
- - test/dummy/config/application.rb
145
- - test/dummy/config/boot.rb
146
- - test/dummy/config/database.yml
147
- - test/dummy/config/environment.rb
148
- - test/dummy/config/environments/development.rb
149
- - test/dummy/config/environments/production.rb
150
- - test/dummy/config/environments/test.rb
151
- - test/dummy/config/initializers/backtrace_silencers.rb
152
- - test/dummy/config/initializers/inflections.rb
153
- - test/dummy/config/initializers/mime_types.rb
154
- - test/dummy/config/initializers/secret_token.rb
155
- - test/dummy/config/initializers/session_store.rb
156
- - test/dummy/config/initializers/wrap_parameters.rb
157
- - test/dummy/config/locales/en.yml
158
- - test/dummy/config/routes.rb
159
- - test/dummy/lib/assets/.gitkeep
160
- - test/dummy/log/.gitkeep
161
- - test/dummy/public/404.html
162
- - test/dummy/public/422.html
163
- - test/dummy/public/500.html
164
- - test/dummy/public/favicon.ico
165
- - test/dummy/script/rails
170
+ - test/dummy_2.3/Rakefile
171
+ - test/dummy_2.3/app/controllers/application_controller.rb
172
+ - test/dummy_2.3/app/models/group.rb
173
+ - test/dummy_2.3/app/models/person.rb
174
+ - test/dummy_2.3/config/boot.rb
175
+ - test/dummy_2.3/config/database.yml
176
+ - test/dummy_2.3/config/environment.rb
177
+ - test/dummy_2.3/config/environments/development.rb
178
+ - test/dummy_2.3/config/environments/test.rb
179
+ - test/dummy_2.3/config/initializers/backtrace_silencers.rb
180
+ - test/dummy_2.3/config/initializers/bundler.rb
181
+ - test/dummy_2.3/config/initializers/cookie_verification_secret.rb
182
+ - test/dummy_2.3/config/initializers/inflections.rb
183
+ - test/dummy_2.3/config/initializers/mime_types.rb
184
+ - test/dummy_2.3/config/initializers/new_rails_defaults.rb
185
+ - test/dummy_2.3/config/initializers/session_store.rb
186
+ - test/dummy_2.3/config/locales/en.yml
187
+ - test/dummy_2.3/config/routes.rb
188
+ - test/dummy_2.3/db/migrate/20110922194432_create_people.rb
189
+ - test/dummy_2.3/db/migrate/20110922194512_create_groups.rb
190
+ - test/dummy_2.3/db/schema.rb
191
+ - test/dummy_2.3/db/seeds.rb
192
+ - test/dummy_2.3/script/about
193
+ - test/dummy_2.3/script/console
194
+ - test/dummy_2.3/script/dbconsole
195
+ - test/dummy_2.3/script/destroy
196
+ - test/dummy_2.3/script/generate
197
+ - test/dummy_2.3/script/performance/benchmarker
198
+ - test/dummy_2.3/script/performance/profiler
199
+ - test/dummy_2.3/script/plugin
200
+ - test/dummy_2.3/script/runner
201
+ - test/dummy_2.3/script/server
202
+ - test/dummy_2.3/test/fixtures/groups.yml
203
+ - test/dummy_2.3/test/fixtures/people.yml
204
+ - test/dummy_3.1/Rakefile
205
+ - test/dummy_3.1/app/controllers/application_controller.rb
206
+ - test/dummy_3.1/app/models/.gitkeep
207
+ - test/dummy_3.1/app/models/group.rb
208
+ - test/dummy_3.1/app/models/person.rb
209
+ - test/dummy_3.1/config.ru
210
+ - test/dummy_3.1/config/application.rb
211
+ - test/dummy_3.1/config/boot.rb
212
+ - test/dummy_3.1/config/database.yml
213
+ - test/dummy_3.1/config/environment.rb
214
+ - test/dummy_3.1/config/environments/development.rb
215
+ - test/dummy_3.1/config/environments/test.rb
216
+ - test/dummy_3.1/config/initializers/backtrace_silencers.rb
217
+ - test/dummy_3.1/config/initializers/inflections.rb
218
+ - test/dummy_3.1/config/initializers/mime_types.rb
219
+ - test/dummy_3.1/config/initializers/secret_token.rb
220
+ - test/dummy_3.1/config/initializers/session_store.rb
221
+ - test/dummy_3.1/config/initializers/wrap_parameters.rb
222
+ - test/dummy_3.1/config/locales/en.yml
223
+ - test/dummy_3.1/config/routes.rb
224
+ - test/dummy_3.1/db/migrate/20110922194058_create_people.rb
225
+ - test/dummy_3.1/db/migrate/20110922194126_create_groups.rb
226
+ - test/dummy_3.1/db/schema.rb
227
+ - test/dummy_3.1/lib/assets/.gitkeep
228
+ - test/dummy_3.1/log/.gitkeep
229
+ - test/dummy_3.1/script/rails
230
+ - test/dummy_3.1/test/fixtures/groups.yml
231
+ - test/dummy_3.1/test/fixtures/people.yml
166
232
  - test/liszt_test.rb
233
+ - test/redis.conf
234
+ - test/redis_list_test.rb
167
235
  - test/test_helper.rb
@@ -1,7 +0,0 @@
1
- // This is a manifest file that'll be compiled into including all the files listed below.
2
- // Add new JavaScript/Coffee code in separate files in this directory and they'll automatically
3
- // be included in the compiled file accessible from http://example.com/assets/application.js
4
- // It's not advisable to add code directly here, but if you do, it'll appear at the bottom of the
5
- // the compiled file.
6
- //
7
- //= require_tree .
@@ -1,7 +0,0 @@
1
- /*
2
- * This is a manifest file that'll automatically include all the stylesheets available in this directory
3
- * and any sub-directories. You're free to add application-wide styles to this file and they'll appear at
4
- * the top of the compiled file, but it's generally better to create a new file per style scope.
5
- *= require_self
6
- *= require_tree .
7
- */
@@ -1,2 +0,0 @@
1
- module ApplicationHelper
2
- end
@@ -1,14 +0,0 @@
1
- <!DOCTYPE html>
2
- <html>
3
- <head>
4
- <title>Dummy</title>
5
- <%= stylesheet_link_tag "application" %>
6
- <%= javascript_include_tag "application" %>
7
- <%= csrf_meta_tags %>
8
- </head>
9
- <body>
10
-
11
- <%= yield %>
12
-
13
- </body>
14
- </html>
@@ -1,51 +0,0 @@
1
- Dummy::Application.configure do
2
- # Settings specified here will take precedence over those in config/application.rb
3
-
4
- # Code is not reloaded between requests
5
- config.cache_classes = true
6
-
7
- # Full error reports are disabled and caching is turned on
8
- config.consider_all_requests_local = false
9
- config.action_controller.perform_caching = true
10
-
11
- # Disable Rails's static asset server (Apache or nginx will already do this)
12
- config.serve_static_assets = false
13
-
14
- # Compress JavaScripts and CSS
15
- config.assets.compress = true
16
-
17
- # Specifies the header that your server uses for sending files
18
- # (comment out if your front-end server doesn't support this)
19
- config.action_dispatch.x_sendfile_header = "X-Sendfile" # Use 'X-Accel-Redirect' for nginx
20
-
21
- # Force all access to the app over SSL, use Strict-Transport-Security, and use secure cookies.
22
- # config.force_ssl = true
23
-
24
- # See everything in the log (default is :info)
25
- # config.log_level = :debug
26
-
27
- # Use a different logger for distributed setups
28
- # config.logger = SyslogLogger.new
29
-
30
- # Use a different cache store in production
31
- # config.cache_store = :mem_cache_store
32
-
33
- # Enable serving of images, stylesheets, and JavaScripts from an asset server
34
- # config.action_controller.asset_host = "http://assets.example.com"
35
-
36
- # Precompile additional assets (application.js, application.css, and all non-JS/CSS are already added)
37
- # config.assets.precompile += %w( search.js )
38
-
39
- # Disable delivery errors, bad email addresses will be ignored
40
- # config.action_mailer.raise_delivery_errors = false
41
-
42
- # Enable threaded mode
43
- # config.threadsafe!
44
-
45
- # Enable locale fallbacks for I18n (makes lookups for any locale fall back to
46
- # the I18n.default_locale when a translation can not be found)
47
- config.i18n.fallbacks = true
48
-
49
- # Send deprecation notices to registered listeners
50
- config.active_support.deprecation = :notify
51
- end
File without changes
@@ -1,26 +0,0 @@
1
- <!DOCTYPE html>
2
- <html>
3
- <head>
4
- <title>The page you were looking for doesn't exist (404)</title>
5
- <style type="text/css">
6
- body { background-color: #fff; color: #666; text-align: center; font-family: arial, sans-serif; }
7
- div.dialog {
8
- width: 25em;
9
- padding: 0 4em;
10
- margin: 4em auto 0 auto;
11
- border: 1px solid #ccc;
12
- border-right-color: #999;
13
- border-bottom-color: #999;
14
- }
15
- h1 { font-size: 100%; color: #f00; line-height: 1.5em; }
16
- </style>
17
- </head>
18
-
19
- <body>
20
- <!-- This file lives in public/404.html -->
21
- <div class="dialog">
22
- <h1>The page you were looking for doesn't exist.</h1>
23
- <p>You may have mistyped the address or the page may have moved.</p>
24
- </div>
25
- </body>
26
- </html>
@@ -1,26 +0,0 @@
1
- <!DOCTYPE html>
2
- <html>
3
- <head>
4
- <title>The change you wanted was rejected (422)</title>
5
- <style type="text/css">
6
- body { background-color: #fff; color: #666; text-align: center; font-family: arial, sans-serif; }
7
- div.dialog {
8
- width: 25em;
9
- padding: 0 4em;
10
- margin: 4em auto 0 auto;
11
- border: 1px solid #ccc;
12
- border-right-color: #999;
13
- border-bottom-color: #999;
14
- }
15
- h1 { font-size: 100%; color: #f00; line-height: 1.5em; }
16
- </style>
17
- </head>
18
-
19
- <body>
20
- <!-- This file lives in public/422.html -->
21
- <div class="dialog">
22
- <h1>The change you wanted was rejected.</h1>
23
- <p>Maybe you tried to change something you didn't have access to.</p>
24
- </div>
25
- </body>
26
- </html>
@@ -1,26 +0,0 @@
1
- <!DOCTYPE html>
2
- <html>
3
- <head>
4
- <title>We're sorry, but something went wrong (500)</title>
5
- <style type="text/css">
6
- body { background-color: #fff; color: #666; text-align: center; font-family: arial, sans-serif; }
7
- div.dialog {
8
- width: 25em;
9
- padding: 0 4em;
10
- margin: 4em auto 0 auto;
11
- border: 1px solid #ccc;
12
- border-right-color: #999;
13
- border-bottom-color: #999;
14
- }
15
- h1 { font-size: 100%; color: #f00; line-height: 1.5em; }
16
- </style>
17
- </head>
18
-
19
- <body>
20
- <!-- This file lives in public/500.html -->
21
- <div class="dialog">
22
- <h1>We're sorry, but something went wrong.</h1>
23
- <p>We've been notified about this issue and we'll take a look at it shortly.</p>
24
- </div>
25
- </body>
26
- </html>