Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package rubygem-pundit for openSUSE:Factory 
checked in at 2023-06-18 23:07:46
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/rubygem-pundit (Old)
 and      /work/SRC/openSUSE:Factory/.rubygem-pundit.new.15902 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "rubygem-pundit"

Sun Jun 18 23:07:46 2023 rev:6 rq:1093565 version:2.3.0

Changes:
--------
--- /work/SRC/openSUSE:Factory/rubygem-pundit/rubygem-pundit.changes    
2022-02-24 18:23:34.650656535 +0100
+++ /work/SRC/openSUSE:Factory/.rubygem-pundit.new.15902/rubygem-pundit.changes 
2023-06-18 23:07:47.309405461 +0200
@@ -1,0 +2,6 @@
+Fri Jun 16 08:35:04 UTC 2023 - Andrea Manzini <andrea.manz...@suse.com>
+
+- updated to version 2.3.0
+  * add support for rubocop-rspec syntax extensions 
+
+-------------------------------------------------------------------

Old:
----
  pundit-2.2.0.gem

New:
----
  pundit-2.3.0.gem

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ rubygem-pundit.spec ++++++
--- /var/tmp/diff_new_pack.51Oqwm/_old  2023-06-18 23:07:47.969409410 +0200
+++ /var/tmp/diff_new_pack.51Oqwm/_new  2023-06-18 23:07:47.973409434 +0200
@@ -1,7 +1,7 @@
 #
 # spec file for package rubygem-pundit
 #
-# Copyright (c) 2022 SUSE LLC
+# Copyright (c) 2023 SUSE LLC
 #
 # All modifications and additions to the file contributed by third parties
 # remain the property of their copyright owners, unless otherwise agreed
@@ -24,7 +24,7 @@
 #
 
 Name:           rubygem-pundit
-Version:        2.2.0
+Version:        2.3.0
 Release:        0
 %define mod_name pundit
 %define mod_full_name %{mod_name}-%{version}

++++++ pundit-2.2.0.gem -> pundit-2.3.0.gem ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/CHANGELOG.md new/CHANGELOG.md
--- old/CHANGELOG.md    2022-02-11 13:14:56.000000000 +0100
+++ new/CHANGELOG.md    2022-12-19 16:24:04.000000000 +0100
@@ -1,5 +1,11 @@
 # Pundit
 
+## 2.3.0 (2022-12-19)
+
+### Added
+
+- add support for rubocop-rspec syntax extensions (#745)
+
 ## 2.2.0 (2022-02-11)
 
 ### Fixed
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/README.md new/README.md
--- old/README.md       2022-02-11 13:14:56.000000000 +0100
+++ new/README.md       2022-12-19 16:24:04.000000000 +0100
@@ -24,8 +24,8 @@
 
 > **Please note** that the README on GitHub is accurate with the _latest code 
 > on GitHub_. You are most likely using a released version of Pundit, so 
 > please refer to the [documentation for the latest released version of 
 > Pundit](https://www.rubydoc.info/gems/pundit).
 
-``` ruby
-gem "pundit"
+``` sh
+bundle add pundit
 ```
 
 Include `Pundit::Authorization` in your application controller:
@@ -512,7 +512,7 @@
 
   def user_not_authorized
     flash[:alert] = "You are not authorized to perform this action."
-    redirect_to(request.referrer || root_path)
+    redirect_back(fallback_location: root_path)
   end
 end
 ```
@@ -541,7 +541,7 @@
    policy_name = exception.policy.class.to_s.underscore
 
    flash[:error] = t "#{policy_name}.#{exception.query}", scope: "pundit", 
default: :default
-   redirect_to(request.referrer || root_path)
+   redirect_back(fallback_url: root_path)
  end
 end
 ```
@@ -692,7 +692,7 @@
 class PostsController < ApplicationController
   def update
     @post = Post.find(params[:id])
-    if @post.update_attributes(post_params)
+    if @post.update(post_params)
       redirect_to @post
     else
       render :edit
@@ -714,7 +714,7 @@
 class PostsController < ApplicationController
   def update
     @post = Post.find(params[:id])
-    if @post.update_attributes(permitted_attributes(@post))
+    if @post.update(permitted_attributes(@post))
       redirect_to @post
     else
       render :edit
@@ -802,6 +802,16 @@
 
 Pundit does not provide a DSL for testing scopes. Just test it like a regular 
Ruby class!
 
+### Linting with RuboCop RSpec
+
+When you lint your RSpec spec files with `rubocop-rspec`, it will fail to 
properly detect RSpec constructs that Pundit defines, `permissions`.
+Make sure to use `rubocop-rspec` 2.0 or newer and add the following to your 
`.rubocop.yml`:
+
+```yaml
+inherit_gem:
+  pundit: config/rubocop-rspec.yml
+```
+
 # External Resources
 
 - [RailsApps Example Application: Pundit and 
Devise](https://github.com/RailsApps/rails-devise-pundit)
Binary files old/checksums.yaml.gz and new/checksums.yaml.gz differ
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/config/rubocop-rspec.yml new/config/rubocop-rspec.yml
--- old/config/rubocop-rspec.yml        1970-01-01 01:00:00.000000000 +0100
+++ new/config/rubocop-rspec.yml        2022-12-19 16:24:04.000000000 +0100
@@ -0,0 +1,5 @@
+RSpec:
+  Language:
+    ExampleGroups:
+      Regular:
+        - permissions
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/lib/pundit/version.rb new/lib/pundit/version.rb
--- old/lib/pundit/version.rb   2022-02-11 13:14:56.000000000 +0100
+++ new/lib/pundit/version.rb   2022-12-19 16:24:04.000000000 +0100
@@ -1,5 +1,5 @@
 # frozen_string_literal: true
 
 module Pundit
-  VERSION = "2.2.0"
+  VERSION = "2.3.0"
 end
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/lib/pundit.rb new/lib/pundit.rb
--- old/lib/pundit.rb   2022-02-11 13:14:56.000000000 +0100
+++ new/lib/pundit.rb   2022-12-19 16:24:04.000000000 +0100
@@ -55,7 +55,7 @@
   class NotDefinedError < Error; end
 
   def self.included(base)
-    ActiveSupport::Deprecation.warn <<~WARNING.strip_heredoc
+    ActiveSupport::Deprecation.warn <<~WARNING
       'include Pundit' is deprecated. Please use 'include 
Pundit::Authorization' instead.
     WARNING
     base.include Authorization
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/metadata new/metadata
--- old/metadata        2022-02-11 13:14:56.000000000 +0100
+++ new/metadata        2022-12-19 16:24:04.000000000 +0100
@@ -1,7 +1,7 @@
 --- !ruby/object:Gem::Specification
 name: pundit
 version: !ruby/object:Gem::Version
-  version: 2.2.0
+  version: 2.3.0
 platform: ruby
 authors:
 - Jonas Nicklas
@@ -9,7 +9,7 @@
 autorequire:
 bindir: bin
 cert_chain: []
-date: 2022-02-11 00:00:00.000000000 Z
+date: 2022-12-19 00:00:00.000000000 Z
 dependencies:
 - !ruby/object:Gem::Dependency
   name: activesupport
@@ -184,6 +184,7 @@
 - LICENSE.txt
 - README.md
 - Rakefile
+- config/rubocop-rspec.yml
 - lib/generators/pundit/install/USAGE
 - lib/generators/pundit/install/install_generator.rb
 - lib/generators/pundit/install/templates/application_policy.rb
@@ -225,7 +226,7 @@
     - !ruby/object:Gem::Version
       version: '0'
 requirements: []
-rubygems_version: 3.2.32
+rubygems_version: 3.3.7
 signing_key:
 specification_version: 4
 summary: OO authorization for Rails

Reply via email to