Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Comparing changes

Choose two branches to see what's changed or to start a new pull request. If you need to, you can also compare across forks.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also compare across forks.
base fork: gaelian/enki
base: 2432203000
...
head fork: gaelian/enki
compare: ed9ab619d8
Checking mergeability… Don't worry, you can still create the pull request.
  • 10 commits
  • 7 files changed
  • 0 commit comments
  • 2 contributors
View
3  .travis.yml
@@ -0,0 +1,3 @@
+before_script:
+ - "cp config/database.example.yml config/database.yml"
+script: "bundle exec rake db:migrate --trace && bundle exec rake --trace"
View
14 Gemfile
@@ -5,7 +5,15 @@ gem 'rails', '3.0.4'
# Bundle edge Rails instead:
# gem 'rails', :git => 'git://github.com/rails/rails.git'
-gem 'sqlite3-ruby', :require => 'sqlite3'
+platforms :ruby do
+ gem 'sqlite3-ruby', :require => 'sqlite3'
+end
+
+platforms :jruby do
+ gem 'activerecord-jdbcsqlite3-adapter'
+ gem 'trinidad'
+ gem 'jruby-openssl'
+end
# Use unicorn as the web server
# gem 'unicorn'
@@ -17,7 +25,7 @@ gem 'sqlite3-ruby', :require => 'sqlite3'
# gem 'ruby-debug'
# Bundle the extra gems:
-gem 'RedCloth', :require => 'redcloth'
+gem 'RedCloth', '~> 4.2.7', :require => 'redcloth'
gem 'ruby-openid', :require => 'openid'
gem 'rack-openid', :require => 'rack/openid'
gem 'aaronh-chronic', :require => 'chronic' # Fixes for 1.9.2
@@ -35,5 +43,5 @@ group :development, :test do
gem 'factory_girl'
gem 'rspec'
gem 'rspec-rails'
- gem 'hpricot'
+ gem 'nokogiri', '~> 1.5.0'
end
View
30 Gemfile.lock
@@ -1,7 +1,7 @@
GEM
remote: http://rubygems.org/
specs:
- RedCloth (4.2.7)
+ RedCloth (4.2.8)
aaronh-chronic (0.3.9)
abstract (1.0.0)
actionmailer (3.0.4)
@@ -26,11 +26,16 @@ GEM
activesupport (= 3.0.4)
arel (~> 2.0.2)
tzinfo (~> 0.3.23)
+ activerecord-jdbc-adapter (1.2.0)
+ activerecord-jdbcsqlite3-adapter (1.2.0)
+ activerecord-jdbc-adapter (~> 1.2.0)
+ jdbc-sqlite3 (~> 3.7.2)
activeresource (3.0.4)
activemodel (= 3.0.4)
activesupport (= 3.0.4)
activesupport (3.0.4)
arel (2.0.8)
+ bouncy-castle-java (1.5.0146.1)
builder (2.1.2)
coderay (0.9.7)
cucumber (0.10.0)
@@ -51,9 +56,15 @@ GEM
i18n (~> 0.4)
gherkin (2.3.3)
json (~> 1.4.6)
- hpricot (0.8.3)
+ gherkin (2.3.3-java)
+ json (~> 1.4.6)
i18n (0.5.0)
+ jdbc-sqlite3 (3.7.2)
+ jruby-openssl (0.7.4)
+ bouncy-castle-java
+ jruby-rack (1.0.10)
json (1.4.6)
+ json (1.4.6-java)
lesstile (1.0.1)
mail (2.2.15)
activesupport (>= 2.3.6)
@@ -61,7 +72,8 @@ GEM
mime-types (~> 1.16)
treetop (~> 1.4.8)
mime-types (1.16)
- nokogiri (1.4.4)
+ nokogiri (1.5.0)
+ nokogiri (1.5.0-java)
polyglot (0.3.1)
rack (1.2.1)
rack-mount (0.6.13)
@@ -106,6 +118,10 @@ GEM
thor (0.14.6)
treetop (1.4.9)
polyglot (>= 0.3.1)
+ trinidad (1.2.3)
+ jruby-rack (>= 1.0.9)
+ trinidad_jars (>= 1.0.1)
+ trinidad_jars (1.0.1)
tzinfo (0.3.24)
webrat (0.7.3)
nokogiri (>= 1.2.0)
@@ -114,22 +130,26 @@ GEM
will_paginate (3.0.pre2)
PLATFORMS
+ java
ruby
DEPENDENCIES
- RedCloth
+ RedCloth (~> 4.2.7)
aaronh-chronic
+ activerecord-jdbcsqlite3-adapter
coderay
cucumber-rails
factory_girl
formtastic
- hpricot
+ jruby-openssl
lesstile
+ nokogiri (~> 1.5.0)
rack-openid
rails (= 3.0.4)
rspec
rspec-rails
ruby-openid
sqlite3-ruby
+ trinidad
webrat
will_paginate (= 3.0.pre2)
View
1  config/database.example.yml
@@ -1,4 +1,5 @@
# SQLite version 3.x
+#
# gem install sqlite3-ruby (not necessary on OS X Leopard)
development:
adapter: sqlite3
View
4 spec/controllers/admin/comments_controller_spec.rb
@@ -111,7 +111,7 @@ def do_delete
describe 'handling DELETE to destroy, JSON request' do
before(:each) do
@comment = Comment.new(:author => 'xavier')
- @comment.stub!(:destroy_with_undo).and_return(mock("undo_item", :description => 'hello'))
+ @comment.stub!(:destroy_with_undo).and_return(mock_model(UndoItem, :description => 'hello'))
Comment.stub!(:find).and_return(@comment)
end
@@ -121,7 +121,7 @@ def do_delete
end
it("deletes comment") do
- @comment.should_receive(:destroy_with_undo).and_return(mock("undo_item", :description => 'hello'))
+ @comment.should_receive(:destroy_with_undo).and_return(mock_model(UndoItem, :description => 'hello'))
do_delete
end
View
4 spec/controllers/admin/posts_controller_spec.rb
@@ -147,7 +147,7 @@ def do_delete
describe 'handling DELETE to destroy, JSON request' do
before(:each) do
@post = Post.new(:title => 'A post')
- @post.stub!(:destroy_with_undo).and_return(mock("undo_item", :description => 'hello'))
+ @post.stub!(:destroy_with_undo).and_return(mock_model(UndoItem, :description => 'hello'))
Post.stub!(:find).and_return(@post)
end
@@ -157,7 +157,7 @@ def do_delete
end
it("deletes post") do
- @post.should_receive(:destroy_with_undo).and_return(mock("undo_item", :description => 'hello'))
+ @post.should_receive(:destroy_with_undo).and_return(mock_model(UndoItem, :description => 'hello'))
do_delete
end
View
3  spec/support/be_valid_html5.rb
@@ -1,7 +1,6 @@
# Paste me into spec_helper.rb, or save me somewhere else and require me in.
require 'net/http'
require 'digest/md5'
-require 'hpricot'
class BeValidHtml5
@@ -59,7 +58,7 @@ def matches?(rendered)
unless markup_is_valid
fragment.split($/).each_with_index{|line, index| message << "#{'%04i' % (index+1)} : #{line}#{$/}"} if @@display_invalid_content
@message = "Invalid markup:\n"
- @elements = Hpricot(response.body.force_encoding('utf-8')).search("li.msg_err > span.msg")
+ @elements = Nokogiri::HTML(response.body.force_encoding('utf-8')).css("li.msg_err > span.msg")
(@elements).each { |span| @message << CGI.unescapeHTML(span.inner_html) + "\n" }
end
if markup_is_valid

No commit comments for this range

Something went wrong with that request. Please try again.