solve test error due to rubygem-rack update t0 2.2.0+
(cherry picked from commit 5e75d6676dc2460ce4c0c6767bb96aafd70032a3)
This commit is contained in:
parent
3264f3a896
commit
3ce84bf3e7
@ -3,7 +3,7 @@
|
|||||||
Summary: Ruby-based web application framework
|
Summary: Ruby-based web application framework
|
||||||
Name: rubygem-%{gem_name}
|
Name: rubygem-%{gem_name}
|
||||||
Version: 2.0.3
|
Version: 2.0.3
|
||||||
Release: 1
|
Release: 2
|
||||||
License: MIT
|
License: MIT
|
||||||
URL: http://www.sinatrarb.com/
|
URL: http://www.sinatrarb.com/
|
||||||
Source0: https://rubygems.org/gems/sinatra-%{version}.gem
|
Source0: https://rubygems.org/gems/sinatra-%{version}.gem
|
||||||
@ -51,6 +51,10 @@ for FILE in $(grep -rl '^require.*bundler.*' test/); do
|
|||||||
sed -i "/^require 'bundler.*'/ s/^/#/" ${FILE}
|
sed -i "/^require 'bundler.*'/ s/^/#/" ${FILE}
|
||||||
done
|
done
|
||||||
mv test/integration_test.rb{,.disabled}
|
mv test/integration_test.rb{,.disabled}
|
||||||
|
#solve test error due to rubygem-rack 2.2.0+ changes
|
||||||
|
sed -i '160,162d' test/static_test.rb
|
||||||
|
sed -i '159a\assert(' test/static_test.rb
|
||||||
|
sed -i '160a\response.status == 200 || response.status == 206,' test/static_test.rb
|
||||||
ruby -e 'Dir.glob "./test/*_test.rb", &method(:require)'
|
ruby -e 'Dir.glob "./test/*_test.rb", &method(:require)'
|
||||||
popd
|
popd
|
||||||
%endif
|
%endif
|
||||||
@ -78,5 +82,8 @@ popd
|
|||||||
%{gem_instdir}/examples
|
%{gem_instdir}/examples
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Wed Feb 10 2021 Ge Wang <wangge20@huawei.com> - 2.0.3-2
|
||||||
|
- solve test error due to rubygem-rack update to 2.2.0+
|
||||||
|
|
||||||
* Sat Aug 22 2020 liyanan <liyanan32@huawei.com> - 2.0.3-1
|
* Sat Aug 22 2020 liyanan <liyanan32@huawei.com> - 2.0.3-1
|
||||||
- package init
|
- package init
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user