diff options
Diffstat (limited to 'dev-ruby/sinatra')
-rw-r--r-- | dev-ruby/sinatra/ChangeLog | 6 | ||||
-rw-r--r-- | dev-ruby/sinatra/Manifest | 13 | ||||
-rw-r--r-- | dev-ruby/sinatra/files/sinatra-1.0-haml3-tests.patch | 106 | ||||
-rw-r--r-- | dev-ruby/sinatra/sinatra-1.0.ebuild | 7 |
4 files changed, 123 insertions, 9 deletions
diff --git a/dev-ruby/sinatra/ChangeLog b/dev-ruby/sinatra/ChangeLog index 79af0d004d3c..cbb5b494de40 100644 --- a/dev-ruby/sinatra/ChangeLog +++ b/dev-ruby/sinatra/ChangeLog @@ -1,6 +1,10 @@ # ChangeLog for dev-ruby/sinatra # Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/dev-ruby/sinatra/ChangeLog,v 1.10 2010/08/11 05:36:54 graaff Exp $ +# $Header: /var/cvsroot/gentoo-x86/dev-ruby/sinatra/ChangeLog,v 1.11 2010/08/29 10:28:27 graaff Exp $ + + 29 Aug 2010; Hans de Graaff <graaff@gentoo.org> sinatra-1.0.ebuild, + +files/sinatra-1.0-haml3-tests.patch: + Fix broken tests due to new haml 3 with upstream patch. 11 Aug 2010; Hans de Graaff <graaff@gentoo.org> -sinatra-0.9.4.ebuild, -sinatra-0.9.4-r1.ebuild: diff --git a/dev-ruby/sinatra/Manifest b/dev-ruby/sinatra/Manifest index b1ca84a77214..00154dc0b890 100644 --- a/dev-ruby/sinatra/Manifest +++ b/dev-ruby/sinatra/Manifest @@ -1,14 +1,15 @@ -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA256 +AUX sinatra-1.0-haml3-tests.patch 4084 RMD160 9eb0f8b7f49d15248498b8b524dfb325248a0884 SHA1 a263c0c038f594ae56a048ffa6f0e117f5a73047 SHA256 0c8e0d74816bdceabe170dee8f160fc24f7c35c9ea8b3843a114f9d9e039bec2 DIST sinatra-1.0.gem 121856 RMD160 90b5c985f494574141c0cf33144d2cf206f0eaed SHA1 0f79a20ae46eedd387d5b93a823ecc1f9c4133bb SHA256 8a79ad3209baf34a4dfef6079a5461c381c755750f8a1234c36144a838f67a8a -EBUILD sinatra-1.0.ebuild 872 RMD160 8b52e1da31b2a9b7ab7c02b61abd1b05aefc1f02 SHA1 182ea0ea7cb67d4252c793170c7b96358078f539 SHA256 bdde38c4c39c7d74d7f523969a1a2a370747adf933ec5ae2a8cc9dda86cce15b -MISC ChangeLog 1897 RMD160 2053c7a0dd453baacfc414ab3678358a5406552a SHA1 be4e4f62f552562b2d0b55fa952782e01b1e91f1 SHA256 594960b4d5e77e29e33aaa7793b1628c3928ff922747807867ab7070d4ff8bce +EBUILD sinatra-1.0.ebuild 950 RMD160 44ff681062157b827a2f56b715c19624695085a1 SHA1 6c4556a22daa3856777a8245d7a30d94aa0ac5dd SHA256 a7989e02d4837c4079e47c81ffe9ac2095d5d9b2fc8b9f8c700d48159213c689 +MISC ChangeLog 2066 RMD160 1fc56aadea04c3b9c2a2c83ea5a34cc88a38f3ee SHA1 f1983792a866cf43edc5c3d130bba4ab72ccb307 SHA256 c29d8d7b232a056457113d33cd28a56ec32b72045eb2bf3b40f255dcdd8d86e9 MISC metadata.xml 158 RMD160 097f8145a9994f98be4971b43b23b9e5e8bccb66 SHA1 7ac646714b1ab83fda98f3ccdd8b48a31c148b27 SHA256 70b396ab3c7a63a81cb895b7728bd9eccdc9770afdb9919f2c54694b685f7032 -----BEGIN PGP SIGNATURE----- -Version: GnuPG v2.0.15 (GNU/Linux) +Version: GnuPG v2.0.16 (GNU/Linux) -iF4EAREIAAYFAkxiNvwACgkQZihJkut28SvBjgEAlLrsg5mNFISqkVFG305EsBzW -bc71SHDZAK/KWXsWXmkA/2vbx97oYz3XVEhTEFQ8DSPso6eOiBcROWVkclKoewHe -=4eJA +iF4EAREIAAYFAkx6NlYACgkQZihJkut28SsFWAEAjnLCzSapgB/p3tjVX2z/cwD3 +4oREXK0pSAwKPs/mTH8A+gMuytLKNjm6OFqbR4Juwq9jaR5TGrSel3zY3xD1qH9H +=xSQe -----END PGP SIGNATURE----- diff --git a/dev-ruby/sinatra/files/sinatra-1.0-haml3-tests.patch b/dev-ruby/sinatra/files/sinatra-1.0-haml3-tests.patch new file mode 100644 index 000000000000..de41fb066f07 --- /dev/null +++ b/dev-ruby/sinatra/files/sinatra-1.0-haml3-tests.patch @@ -0,0 +1,106 @@ +commit b5bc740c12024df855991ae7437ef2df113d1ab3 +Author: Simon Rozet <simon@rozet.name> +Date: Wed May 12 07:11:05 2010 +0200 + + fix test for haml 3 + +diff --git a/test/sass_test.rb b/test/sass_test.rb +index 200554c..596e3c4 100644 +--- a/test/sass_test.rb ++++ b/test/sass_test.rb +@@ -13,21 +13,21 @@ class SassTest < Test::Unit::TestCase + end + + it 'renders inline Sass strings' do +- sass_app { sass "#sass\n :background-color #FFF\n" } ++ sass_app { sass "#sass\n :background-color white\n" } + assert ok? +- assert_equal "#sass {\n background-color: #FFF; }\n", body ++ assert_equal "#sass {\n background-color: white; }\n", body + end + + it 'renders .sass files in views path' do + sass_app { sass :hello } + assert ok? +- assert_equal "#sass {\n background-color: #FFF; }\n", body ++ assert_equal "#sass {\n background-color: white; }\n", body + end + + it 'ignores the layout option' do + sass_app { sass :hello, :layout => :layout2 } + assert ok? +- assert_equal "#sass {\n background-color: #FFF; }\n", body ++ assert_equal "#sass {\n background-color: white; }\n", body + end + + it "raises error if template not found" do +@@ -39,44 +39,50 @@ class SassTest < Test::Unit::TestCase + + it "passes SASS options to the Sass engine" do + sass_app { +- sass "#sass\n :background-color #FFF\n :color #000\n", :style => :compact ++ sass "#sass\n :background-color white\n :color black\n", ++ :style => :compact + } + assert ok? +- assert_equal "#sass { background-color: #FFF; color: #000; }\n", body ++ assert_equal "#sass { background-color: white; color: black; }\n", body + end + + it "passes default SASS options to the Sass engine" do + mock_app { + set :sass, {:style => :compact} # default Sass style is :nested + get '/' do +- sass "#sass\n :background-color #FFF\n :color #000\n" ++ sass "#sass\n :background-color white\n :color black\n" + end + } + get '/' + assert ok? +- assert_equal "#sass { background-color: #FFF; color: #000; }\n", body ++ assert_equal "#sass { background-color: white; color: black; }\n", body + end + +- it "merges the default SASS options with the overrides and passes them to the Sass engine" do ++ it "merges the default SASS options with the overrides" do + mock_app { +- set :sass, {:style => :compact, :attribute_syntax => :alternate } # default Sass attribute_syntax is :normal (with : in front) ++ # default Sass attribute_syntax is :normal (with : in front) ++ set :sass, {:style => :compact, :attribute_syntax => :alternate } + get '/' do +- sass "#sass\n background-color: #FFF\n color: #000\n" ++ sass "#sass\n background-color: white\n color: black\n" + end + get '/raised' do +- sass "#sass\n :background-color #FFF\n :color #000\n", :style => :expanded # retains global attribute_syntax settings ++ # retains global attribute_syntax settings ++ sass "#sass\n :background-color white\n :color black\n", ++ :style => :expanded + end + get '/expanded_normal' do +- sass "#sass\n :background-color #FFF\n :color #000\n", :style => :expanded, :attribute_syntax => :normal ++ sass "#sass\n :background-color white\n :color black\n", ++ :style => :expanded, :attribute_syntax => :normal + end + } + get '/' + assert ok? +- assert_equal "#sass { background-color: #FFF; color: #000; }\n", body ++ assert_equal "#sass { background-color: white; color: black; }\n", body + assert_raise(Sass::SyntaxError) { get('/raised') } + get '/expanded_normal' + assert ok? +- assert_equal "#sass {\n background-color: #FFF;\n color: #000;\n}\n", body ++ assert_equal "#sass {\n background-color: white;\n color: black;\n}\n", ++ body + end + end + +diff --git a/test/views/hello.sass b/test/views/hello.sass +index 5a4fd57..090bd4a 100644 +--- a/test/views/hello.sass ++++ b/test/views/hello.sass +@@ -1,2 +1,2 @@ + #sass +- :background-color #FFF ++ :background-color white diff --git a/dev-ruby/sinatra/sinatra-1.0.ebuild b/dev-ruby/sinatra/sinatra-1.0.ebuild index dcd8dd4edf6f..735b3f8d9d93 100644 --- a/dev-ruby/sinatra/sinatra-1.0.ebuild +++ b/dev-ruby/sinatra/sinatra-1.0.ebuild @@ -1,6 +1,6 @@ # Copyright 1999-2010 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/dev-ruby/sinatra/sinatra-1.0.ebuild,v 1.5 2010/06/30 06:47:02 fauli Exp $ +# $Header: /var/cvsroot/gentoo-x86/dev-ruby/sinatra/sinatra-1.0.ebuild,v 1.6 2010/08/29 10:28:27 graaff Exp $ EAPI=2 USE_RUBY="ruby18" @@ -21,10 +21,13 @@ KEYWORDS="~amd64 ~x86" IUSE="" ruby_add_rdepend '>=dev-ruby/rack-1.0' -ruby_add_bdepend "test? ( dev-ruby/rack-test dev-ruby/haml dev-ruby/erubis dev-ruby/builder )" +ruby_add_bdepend "test? ( dev-ruby/rack-test >=dev-ruby/haml-3.0 dev-ruby/erubis dev-ruby/builder )" each_ruby_prepare() { # Remove tests for optional templating system which is not # available in Gentoo. rm test/less_test.rb || die + + # Fix tests with haml3. + epatch "${FILESDIR}/${P}-haml3-tests.patch" } |