decidim-dev 0.4.3 → 0.4.4

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: d9c8abada13b165b05c037a075c770a75f83f797
4
- data.tar.gz: 7516c82b6d19a5d15ed0044e6f3c4bb140bb4cc6
3
+ metadata.gz: 5265649e3685681a751d9769a394558e05fe2398
4
+ data.tar.gz: 86a697f84975eac13ac23c8629381dce2ee0a452
5
5
  SHA512:
6
- metadata.gz: 14ed20c7020e195e63c60a5173b4685010601c3425d09ec8f6b3b55f4aabc1e15bc35f38c93c918743247d5457b5d00225e04bef2da7ba6e24f4407679b9c589
7
- data.tar.gz: 5d52de1c67d2a909c675ba658ca0f8ba369e8d0fa7795add8fa8c1047fa79fe802321247dd37f907a962abbe0df39caa70db53cd1efecd1c212c2e8e4bcba9fe
6
+ metadata.gz: 607fadd5b1568091f4368d03e2c914cae102c324c4ee2439335736e45f9b9efd7542a83057d25c8fee6a5683dbe76f6e2487f75ee9fd48246ca317d658157c59
7
+ data.tar.gz: aeeaaa8502a699258a2fa8f5d705bc7c4033aeade44b4c54c67c0ead6891324877b9cbbfdf757d90bd9e03410754ada279ebdce10213db6d1b42084947b33ae5
@@ -33,7 +33,8 @@ require "rails"
33
33
  require "active_support/core_ext/string"
34
34
  require "decidim/core"
35
35
  require "decidim/core/test"
36
- require "#{__dir__}/rspec_support/feature.rb"
36
+
37
+ require_relative "rspec_support/feature.rb"
37
38
 
38
39
  begin
39
40
  require "#{Decidim::Dev.dummy_app_path}/config/environment"
@@ -1,8 +1,6 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  RSpec.shared_context "feature" do
4
- include Decidim::FeaturePathHelper
5
-
6
4
  let(:manifest) { Decidim.find_feature_manifest(manifest_name) }
7
5
 
8
6
  let(:user) { create :user, :confirmed, organization: organization }
@@ -28,7 +26,7 @@ RSpec.shared_context "feature" do
28
26
  end
29
27
 
30
28
  def visit_feature
31
- page.visit feature_path(feature)
29
+ page.visit main_feature_path(feature)
32
30
  end
33
31
  end
34
32
 
@@ -3,14 +3,7 @@
3
3
  RSpec.configure do |config|
4
4
  config.before(:suite) do
5
5
  I18n.config.enforce_available_locales = false
6
- end
7
-
8
- config.around(:each) do |example|
9
6
  I18n.available_locales = %w(en ca es)
10
7
  Decidim.available_locales = %w(en ca es)
11
-
12
- previous_locale = I18n.locale
13
- example.run
14
- I18n.locale = previous_locale
15
8
  end
16
9
  end
@@ -5,7 +5,7 @@
5
5
  var setTimeoutFunc = setTimeout;
6
6
 
7
7
  function noop() {}
8
-
8
+
9
9
  // Polyfill for Function.prototype.bind
10
10
  function bind(fn, thisArg) {
11
11
  return function () {
@@ -223,7 +223,7 @@
223
223
  Promise._setUnhandledRejectionFn = function _setUnhandledRejectionFn(fn) {
224
224
  Promise._unhandledRejectionFn = fn;
225
225
  };
226
-
226
+
227
227
  if (typeof module !== 'undefined' && module.exports) {
228
228
  module.exports = Promise;
229
229
  } else if (!root.Promise) {
@@ -0,0 +1,6 @@
1
+ # frozen_string_literal: true
2
+
3
+ RSpec.configure do |config|
4
+ config.include Decidim::FeaturePathHelper
5
+ config.include Decidim::ResourceHelper
6
+ end
@@ -48,8 +48,6 @@ module Decidim
48
48
  end
49
49
 
50
50
  def decidim_dev
51
- template "decidim_dev.rb", "#{dummy_app_path}/config/initializers/decidim_dev.rb"
52
-
53
51
  # TODO: Remove these after PhantomJS updates WebKit version (see YML and
54
52
  # initializer comments)
55
53
  template "autoprefixer.yml", "#{dummy_app_path}/config/autoprefixer.yml"
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: decidim-dev
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.3
4
+ version: 0.4.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Josep Jaume Rey Peroy
@@ -10,7 +10,7 @@ authors:
10
10
  autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2017-07-25 00:00:00.000000000 Z
13
+ date: 2017-08-02 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: decidim
@@ -18,14 +18,14 @@ dependencies:
18
18
  requirements:
19
19
  - - '='
20
20
  - !ruby/object:Gem::Version
21
- version: 0.4.3
21
+ version: 0.4.4
22
22
  type: :runtime
23
23
  prerelease: false
24
24
  version_requirements: !ruby/object:Gem::Requirement
25
25
  requirements:
26
26
  - - '='
27
27
  - !ruby/object:Gem::Version
28
- version: 0.4.3
28
+ version: 0.4.4
29
29
  - !ruby/object:Gem::Dependency
30
30
  name: factory_girl_rails
31
31
  requirement: !ruby/object:Gem::Requirement
@@ -370,7 +370,6 @@ files:
370
370
  - lib/decidim/dev/test/rspec_support/authorization_handlers.rb
371
371
  - lib/decidim/dev/test/rspec_support/capybara.rb
372
372
  - lib/decidim/dev/test/rspec_support/database_cleaner.rb
373
- - lib/decidim/dev/test/rspec_support/engine_routes.rb
374
373
  - lib/decidim/dev/test/rspec_support/factory_girl.rb
375
374
  - lib/decidim/dev/test/rspec_support/feature.rb
376
375
  - lib/decidim/dev/test/rspec_support/feature_context.rb
@@ -381,6 +380,7 @@ files:
381
380
  - lib/decidim/dev/test/rspec_support/phantomjs_polyfills/phantomjs-getOwnPropertyNames.js
382
381
  - lib/decidim/dev/test/rspec_support/phantomjs_polyfills/phantomjs-shim.js
383
382
  - lib/decidim/dev/test/rspec_support/phantomjs_polyfills/promise.js
383
+ - lib/decidim/dev/test/rspec_support/route_helpers.rb
384
384
  - lib/decidim/dev/test/rspec_support/translation_helpers.rb
385
385
  - lib/decidim/dev/test/rspec_support/warden.rb
386
386
  - lib/decidim/dev/test/rspec_support/webmock.rb
@@ -389,7 +389,6 @@ files:
389
389
  - lib/generators/decidim/dummy_generator.rb
390
390
  - lib/generators/decidim/templates/autoprefixer.yml
391
391
  - lib/generators/decidim/templates/autoprefixer_initializer.rb
392
- - lib/generators/decidim/templates/decidim_dev.rb
393
392
  - lib/tasks/locale_checker.rake
394
393
  - lib/tasks/test_app.rake
395
394
  homepage: https://github.com/decidim/decidim
@@ -1,35 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- module Decidim
4
- # This is a quick hack so all controller specs have their engine's routes
5
- # included as well as our Devise mapping.
6
- module ControllerRequests
7
- extend ActiveSupport::Concern
8
-
9
- included do
10
- begin
11
- engine = (ENV["ENGINE_NAME"].to_s.split("-").map(&:capitalize).join("::") + "::Engine").constantize
12
-
13
- load_routes engine if engine.respond_to?(:routes)
14
- rescue NameError => _exception
15
- puts "Failed to automatically inject routes for engine #{ENV["ENGINE_NAME"]}"
16
- end
17
- end
18
-
19
- class_methods do
20
- def load_routes(klass)
21
- routes do
22
- klass.routes
23
- end
24
- end
25
- end
26
- end
27
- end
28
-
29
- RSpec.configure do |config|
30
- config.include Decidim::ControllerRequests, type: :controller
31
-
32
- config.before :each, type: :controller do
33
- @request.env["devise.mapping"] = Devise.mappings[:user]
34
- end
35
- end
@@ -1,3 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- require "decidim/dev"