Permalink
Browse files

Modernize gemfile, rake tasks, specs

  • Loading branch information...
nateberkopec committed Jun 27, 2015
1 parent 3908837 commit b8c58ee85b54bdfce3e16cf2680e7ca970fd0a12
Showing with 49 additions and 105 deletions.
  1. +3 −6 Gemfile
  2. +9 −2 Manifest
  3. +6 −12 Rakefile
  4. +1 −2 lib/terminal-table.rb
  5. +0 −3 lib/terminal-table/import.rb
  6. +0 −5 spec/cell_spec.rb
  7. +0 −1 spec/import_spec.rb
  8. +0 −1 spec/row_spec.rb
  9. +8 −2 spec/spec_helper.rb
  10. +3 −4 spec/table_spec.rb
  11. +0 −13 tasks/docs.rake
  12. +0 −3 tasks/gemspec.rake
  13. +0 −25 tasks/spec.rake
  14. +19 −26 terminal-table.gemspec
View
9 Gemfile 100755 → 100644
@@ -1,7 +1,4 @@
source 'http://rubygems.org'
source 'https://rubygems.org'
group :test do
gem 'echoe'
gem 'rspec', '1.3.1'
gem 'term-ansicolor', :require => "term/ansicolor"
end
# Specify your gem's dependencies in test-gem.gemspec
gemspec
View
@@ -1,20 +1,27 @@
Gemfile
History.rdoc
Manifest
README.rdoc
Rakefile
Todo.rdoc
examples/examples.rb
lib/terminal-table.rb
lib/terminal-table/cell.rb
lib/terminal-table/import.rb
lib/terminal-table/row.rb
lib/terminal-table/separator.rb
lib/terminal-table/style.rb
lib/terminal-table/table.rb
lib/terminal-table/table_helper.rb
lib/terminal-table/version.rb
spec/cell_spec.rb
spec/import_spec.rb
spec/row_spec.rb
spec/spec_helper.rb
spec/table_helper_spec.rb
spec/table_spec.rb
tasks/docs.rake
tasks/gemspec.rake
tasks/spec.rake
terminal-table.gemspec
terminal-table.sublime-project
terminal-table.sublime-workspace
Manifest
View
@@ -1,15 +1,9 @@
require "bundler/gem_tasks"
require 'rubygems'
require 'rake'
require 'echoe'
require './lib/terminal-table.rb'
Echoe.new("terminal-table", Terminal::Table::VERSION) do |p|
p.author = "TJ Holowaychuk"
p.email = "tj@vision-media.ca"
p.summary = "Simple, feature rich ascii table generation library"
p.url = "http://github.com/visionmedia/terminal-table"
p.runtime_dependencies = []
desc "Run specs"
task :spec do
sh "bundle exec rspec -f progress"
end
Dir['tasks/**/*.rake'].sort.each { |lib| load lib }
desc "Default: Run specs"
task :default => [:spec]
View
@@ -21,7 +21,6 @@
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
#++
$:.unshift File.dirname(__FILE__)
%w(version table cell row separator style table_helper).each do |file|
%w(cell row separator style table table_helper version).each do |file|
require "terminal-table/#{file}"
end
@@ -1,4 +1 @@
require 'terminal-table'
include Terminal::Table::TableHelper
View
@@ -1,8 +1,3 @@
require 'rubygems'
require 'term/ansicolor'
class String; include Term::ANSIColor; end
require 'spec_helper'
describe Terminal::Table do
View
@@ -1,4 +1,3 @@
require 'spec_helper'
require "terminal-table/import"
View
@@ -1,4 +1,3 @@
require 'spec_helper'
describe Terminal::Table do
View
@@ -1,8 +1,14 @@
require File.dirname(__FILE__) + '/../lib/terminal-table'
require 'terminal-table'
require 'term/ansicolor'
class String
include Term::ANSIColor
def deindent
strip.gsub(/^ */, '')
end
end
RSpec.configure do |c|
c.expect_with(:rspec) { |c| c.syntax = :should }
end
View
@@ -1,4 +1,3 @@
require 'spec_helper'
module Terminal
@@ -180,7 +179,7 @@ module Terminal
@table << ['c', 3]
@table << ['d', 'x' * 22]
@table.style.width = 21
expect { @table.render }.to raise_error "Table width exceeds wanted width of 21 characters."
lambda { @table.render }.should raise_error "Table width exceeds wanted width of 21 characters."
end
it "should render title properly" do
@@ -397,14 +396,14 @@ module Terminal
it "should not be equal if the other object does not respond_to? :headings" do
table_one = Table.new
table_two = Object.new
table_two.stub!(:rows).and_return([])
allow(table_two).to receive(:rows).and_return([])
table_one.should_not == table_two
end
it "should not be equal if the other object does not respond_to? :rows" do
table_one = Table.new
table_two = Object.new
table_two.stub!(:rows).and_return([])
allow(table_two).to receive(:rows).and_return([])
table_one.should_not == table_two
end
end
View

This file was deleted.

Oops, something went wrong.
View

This file was deleted.

Oops, something went wrong.
View

This file was deleted.

Oops, something went wrong.
View
@@ -1,31 +1,24 @@
# -*- encoding: utf-8 -*-
# coding: utf-8
lib = File.expand_path('../lib', __FILE__)
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
require 'terminal-table/version'
Gem::Specification.new do |s|
s.name = %q{terminal-table}
s.version = "1.5.0"
Gem::Specification.new do |spec|
spec.name = "terminal-table"
spec.version = Terminal::Table::VERSION
spec.authors = ["TJ Holowaychuk", "Scott J. Goldman"]
spec.email = ["tj@vision-media.ca"]
s.required_rubygems_version = Gem::Requirement.new(">= 1.2") if s.respond_to? :required_rubygems_version=
s.authors = ["TJ Holowaychuk", "Scott J. Goldman"]
s.date = %q{2011-10-13}
s.description = %q{Simple, feature rich ascii table generation library}
s.email = %q{tj@vision-media.ca}
s.extra_rdoc_files = ["README.rdoc", "lib/terminal-table.rb", "lib/terminal-table/cell.rb", "lib/terminal-table/import.rb", "lib/terminal-table/table.rb", "lib/terminal-table/table_helper.rb", "lib/terminal-table/version.rb", "tasks/docs.rake", "tasks/gemspec.rake", "tasks/spec.rake"]
s.files = ["History.rdoc", "Manifest", "README.rdoc", "Rakefile", "Todo.rdoc", "examples/examples.rb", "lib/terminal-table.rb", "lib/terminal-table/cell.rb", "lib/terminal-table/import.rb", "lib/terminal-table/table.rb", "lib/terminal-table/table_helper.rb", "lib/terminal-table/version.rb", "spec/cell_spec.rb", "spec/import_spec.rb", "spec/spec_helper.rb", "spec/table_spec.rb", "tasks/docs.rake", "tasks/gemspec.rake", "tasks/spec.rake", "terminal-table.gemspec"]
s.homepage = %q{http://github.com/visionmedia/terminal-table}
s.license = %q{MIT}
s.rdoc_options = ["--line-numbers", "--inline-source", "--title", "Terminal-table", "--main", "README.rdoc"]
s.require_paths = ["lib"]
s.rubyforge_project = %q{terminal-table}
s.rubygems_version = %q{1.3.5}
s.summary = %q{Simple, feature rich ascii table generation library}
spec.summary = "Simple, feature rich ascii table generation library"
spec.homepage = "https://github.com/tj/terminal-table"
spec.license = "MIT"
if s.respond_to? :specification_version then
current_version = Gem::Specification::CURRENT_SPECIFICATION_VERSION
s.specification_version = 3
spec.files = `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
spec.require_paths = ["lib"]
if Gem::Version.new(Gem::RubyGemsVersion) >= Gem::Version.new('1.2.0') then
else
end
else
end
spec.add_development_dependency "bundler", "~> 1.10"
spec.add_development_dependency "rake", "~> 10.0"
spec.add_development_dependency "rspec", ">= 3.0"
spec.add_development_dependency "term-ansicolor"
spec.add_development_dependency "pry"
end

0 comments on commit b8c58ee

Please sign in to comment.