tty-table 0.10.0 → 0.11.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (150) hide show
  1. checksums.yaml +5 -5
  2. data/CHANGELOG.md +13 -0
  3. data/README.md +67 -3
  4. data/Rakefile +2 -0
  5. data/lib/tty-table.rb +0 -3
  6. data/lib/tty/table.rb +35 -12
  7. data/lib/tty/table/alignment_set.rb +2 -2
  8. data/lib/tty/table/border.rb +6 -3
  9. data/lib/tty/table/border/ascii.rb +1 -1
  10. data/lib/tty/table/border/null.rb +3 -2
  11. data/lib/tty/table/border/row_line.rb +1 -1
  12. data/lib/tty/table/border/unicode.rb +1 -2
  13. data/lib/tty/table/border_dsl.rb +3 -3
  14. data/lib/tty/table/border_options.rb +21 -1
  15. data/lib/tty/table/column_constraint.rb +1 -1
  16. data/lib/tty/table/columns.rb +0 -1
  17. data/lib/tty/table/empty.rb +2 -0
  18. data/lib/tty/table/error.rb +1 -1
  19. data/lib/tty/table/field.rb +1 -1
  20. data/lib/tty/table/header.rb +1 -1
  21. data/lib/tty/table/indentation.rb +2 -3
  22. data/lib/tty/table/operation/alignment.rb +8 -6
  23. data/lib/tty/table/operation/escape.rb +1 -1
  24. data/lib/tty/table/operation/filter.rb +1 -1
  25. data/lib/tty/table/operation/padding.rb +1 -9
  26. data/lib/tty/table/operation/truncation.rb +1 -1
  27. data/lib/tty/table/operation/wrapped.rb +1 -1
  28. data/lib/tty/table/operations.rb +1 -1
  29. data/lib/tty/table/options.rb +1 -1
  30. data/lib/tty/table/orientation.rb +1 -1
  31. data/lib/tty/table/orientation/horizontal.rb +1 -1
  32. data/lib/tty/table/orientation/vertical.rb +1 -1
  33. data/lib/tty/table/renderer.rb +4 -4
  34. data/lib/tty/table/renderer/ascii.rb +1 -1
  35. data/lib/tty/table/renderer/basic.rb +19 -20
  36. data/lib/tty/table/renderer/unicode.rb +1 -1
  37. data/lib/tty/table/row.rb +2 -2
  38. data/lib/tty/table/transformation.rb +2 -2
  39. data/lib/tty/table/validatable.rb +1 -1
  40. data/lib/tty/table/version.rb +3 -1
  41. data/spec/spec_helper.rb +1 -1
  42. data/spec/unit/access_spec.rb +1 -3
  43. data/spec/unit/add_row_spec.rb +1 -3
  44. data/spec/unit/alignment_set/each_spec.rb +1 -3
  45. data/spec/unit/alignment_set/new_spec.rb +1 -3
  46. data/spec/unit/alignment_set/to_ary_spec.rb +1 -3
  47. data/spec/unit/alignment_spec.rb +1 -3
  48. data/spec/unit/border/ascii/rendering_spec.rb +1 -3
  49. data/spec/unit/border/new_spec.rb +1 -3
  50. data/spec/unit/border/null/rendering_spec.rb +1 -3
  51. data/spec/unit/border/options/from_spec.rb +1 -3
  52. data/spec/unit/border/options/new_spec.rb +1 -3
  53. data/spec/unit/border/unicode/rendering_spec.rb +1 -3
  54. data/spec/unit/border_options/new_spec.rb +1 -3
  55. data/spec/unit/border_options/update_spec.rb +1 -3
  56. data/spec/unit/column_constraint/enforce_spec.rb +1 -3
  57. data/spec/unit/column_constraint/widths_spec.rb +1 -3
  58. data/spec/unit/columns/extract_widths_spec.rb +1 -1
  59. data/spec/unit/columns/total_width_spec.rb +0 -1
  60. data/spec/unit/columns/widths_from_spec.rb +1 -1
  61. data/spec/unit/data_spec.rb +1 -3
  62. data/spec/unit/each_spec.rb +1 -3
  63. data/spec/unit/each_with_index_spec.rb +1 -3
  64. data/spec/unit/empty_spec.rb +1 -3
  65. data/spec/unit/eql_spec.rb +1 -3
  66. data/spec/unit/field/equality_spec.rb +1 -3
  67. data/spec/unit/field/length_spec.rb +1 -3
  68. data/spec/unit/field/lines_spec.rb +1 -3
  69. data/spec/unit/field/new_spec.rb +1 -3
  70. data/spec/unit/field/width_spec.rb +1 -3
  71. data/spec/unit/filter_spec.rb +1 -3
  72. data/spec/unit/header/call_spec.rb +1 -3
  73. data/spec/unit/header/color_spec.rb +1 -3
  74. data/spec/unit/header/equality_spec.rb +1 -3
  75. data/spec/unit/header/height_spec.rb +1 -3
  76. data/spec/unit/header/new_spec.rb +1 -4
  77. data/spec/unit/header/set_spec.rb +1 -3
  78. data/spec/unit/header/to_ary_spec.rb +1 -3
  79. data/spec/unit/header_spec.rb +1 -3
  80. data/spec/unit/indentation/indent_spec.rb +1 -3
  81. data/spec/unit/new_spec.rb +1 -3
  82. data/spec/unit/operation/alignment/call_spec.rb +1 -3
  83. data/spec/unit/operation/escape/call_spec.rb +1 -3
  84. data/spec/unit/operation/filter/call_spec.rb +1 -3
  85. data/spec/unit/operation/truncation/call_spec.rb +1 -3
  86. data/spec/unit/operation/wrapped/call_spec.rb +1 -3
  87. data/spec/unit/operations/new_spec.rb +1 -1
  88. data/spec/unit/options/access_spec.rb +1 -3
  89. data/spec/unit/options_spec.rb +1 -3
  90. data/spec/unit/orientation_spec.rb +1 -3
  91. data/spec/unit/padding_spec.rb +1 -3
  92. data/spec/unit/properties_spec.rb +1 -3
  93. data/spec/unit/render_repeat_spec.rb +1 -4
  94. data/spec/unit/render_spec.rb +1 -3
  95. data/spec/unit/render_with_spec.rb +1 -3
  96. data/spec/unit/renderer/ascii/coloring_spec.rb +16 -3
  97. data/spec/unit/renderer/ascii/indentation_spec.rb +1 -3
  98. data/spec/unit/renderer/ascii/multiline_spec.rb +1 -3
  99. data/spec/unit/renderer/ascii/padding_spec.rb +1 -3
  100. data/spec/unit/renderer/ascii/render_spec.rb +1 -3
  101. data/spec/unit/renderer/ascii/resizing_spec.rb +1 -3
  102. data/spec/unit/renderer/ascii/separator_spec.rb +14 -4
  103. data/spec/unit/renderer/basic/alignment_spec.rb +1 -3
  104. data/spec/unit/renderer/basic/coloring_spec.rb +1 -3
  105. data/spec/unit/renderer/basic/extract_column_widths_spec.rb +1 -3
  106. data/spec/unit/renderer/basic/filter_spec.rb +1 -3
  107. data/spec/unit/renderer/basic/indentation_spec.rb +1 -3
  108. data/spec/unit/renderer/basic/multiline_spec.rb +1 -3
  109. data/spec/unit/renderer/basic/new_spec.rb +1 -3
  110. data/spec/unit/renderer/basic/options_spec.rb +1 -3
  111. data/spec/unit/renderer/basic/padding_spec.rb +1 -3
  112. data/spec/unit/renderer/basic/render_spec.rb +1 -3
  113. data/spec/unit/renderer/basic/resizing_spec.rb +1 -3
  114. data/spec/unit/renderer/basic/separator_spec.rb +1 -3
  115. data/spec/unit/renderer/basic/single_row_separator_spec.rb +80 -0
  116. data/spec/unit/renderer/basic/truncation_spec.rb +1 -3
  117. data/spec/unit/renderer/basic/wrapping_spec.rb +1 -3
  118. data/spec/unit/renderer/border_spec.rb +1 -3
  119. data/spec/unit/renderer/render_spec.rb +1 -3
  120. data/spec/unit/renderer/select_spec.rb +1 -3
  121. data/spec/unit/renderer/unicode/coloring_spec.rb +1 -3
  122. data/spec/unit/renderer/unicode/indentation_spec.rb +1 -3
  123. data/spec/unit/renderer/unicode/padding_spec.rb +1 -3
  124. data/spec/unit/renderer/unicode/render_spec.rb +1 -3
  125. data/spec/unit/renderer/unicode/separator_spec.rb +13 -3
  126. data/spec/unit/renderer_spec.rb +1 -3
  127. data/spec/unit/rotate_spec.rb +1 -3
  128. data/spec/unit/row/access_spec.rb +1 -3
  129. data/spec/unit/row/call_spec.rb +1 -3
  130. data/spec/unit/row/data_spec.rb +1 -3
  131. data/spec/unit/row/each_spec.rb +1 -3
  132. data/spec/unit/row/equality_spec.rb +1 -3
  133. data/spec/unit/row/height_spec.rb +1 -3
  134. data/spec/unit/row/new_spec.rb +1 -3
  135. data/spec/unit/row/to_ary_spec.rb +1 -3
  136. data/spec/unit/to_s_spec.rb +1 -1
  137. data/spec/unit/transformation/extract_tuples_spec.rb +1 -3
  138. data/spec/unit/utf_spec.rb +1 -3
  139. data/spec/unit/validatable/validate_options_spec.rb +1 -3
  140. data/spec/unit/validatable_spec.rb +1 -3
  141. data/tasks/console.rake +1 -0
  142. data/tty-table.gemspec +19 -10
  143. metadata +21 -27
  144. data/.gitignore +0 -14
  145. data/.rspec +0 -3
  146. data/.travis.yml +0 -26
  147. data/CODE_OF_CONDUCT.md +0 -49
  148. data/Gemfile +0 -17
  149. data/appveyor.yml +0 -21
  150. data/benchmarks/speed.rb +0 -39
@@ -1,6 +1,4 @@
1
- # coding: utf-8
2
-
3
- require 'spec_helper'
1
+ # frozen_string_literal: true
4
2
 
5
3
  RSpec.describe TTY::Table::ColumnConstraint, '#enforce' do
6
4
  let(:header) { ['h1', 'h2', 'h3', 'h4'] }
@@ -1,6 +1,4 @@
1
- # coding: utf-8
2
-
3
- require 'spec_helper'
1
+ # frozen_string_literal: true
4
2
 
5
3
  RSpec.describe TTY::Table::ColumnConstraint, 'column widths' do
6
4
  let(:header) { ['h1', 'h2', 'h3', 'h4'] }
@@ -1,4 +1,4 @@
1
- # coding: utf-8
1
+ # frozen_string_literal: true
2
2
 
3
3
  RSpec.describe TTY::Table::Columns, '#extract_widths' do
4
4
  let(:color) { Pastel.new(enabled: true) }
@@ -1,4 +1,3 @@
1
- # coding: utf-8
2
1
  # frozen_string_literal: true
3
2
 
4
3
  RSpec.describe TTY::Table::Columns, '#extract_widths!' do
@@ -1,4 +1,4 @@
1
- # coding: utf-8
1
+ # frozen_string_literal: true
2
2
 
3
3
  RSpec.describe TTY::Table::Columns, '#widths_from' do
4
4
  let(:header) { ['h1', 'h2', 'h3'] }
@@ -1,6 +1,4 @@
1
- # coding: utf-8
2
-
3
- require 'spec_helper'
1
+ # frozen_string_literal: true
4
2
 
5
3
  RSpec.describe TTY::Table, '.data' do
6
4
  it 'gets all table data' do
@@ -1,6 +1,4 @@
1
- # encoding: utf-8
2
-
3
- require 'spec_helper'
1
+ # frozen_string_literal: true
4
2
 
5
3
  RSpec.describe TTY::Table, '#each' do
6
4
  let(:header) { ['Header1'] }
@@ -1,6 +1,4 @@
1
- # coding: utf-8
2
-
3
- require 'spec_helper'
1
+ # frozen_string_literal: true
4
2
 
5
3
  RSpec.describe TTY::Table, '.each_with_index' do
6
4
 
@@ -1,6 +1,4 @@
1
- # coding: utf-8
2
-
3
- require 'spec_helper'
1
+ # frozen_string_literal: true
4
2
 
5
3
  RSpec.describe TTY::Table, '#empty?' do
6
4
  let(:header) { ['Header1', 'Header2'] }
@@ -1,6 +1,4 @@
1
- # coding: utf-8
2
-
3
- require 'spec_helper'
1
+ # frozen_string_literal: true
4
2
 
5
3
  RSpec.describe TTY::Table, '#eql?' do
6
4
  let(:rows) { [['a1', 'a2'], ['b1', 'b2']] }
@@ -1,6 +1,4 @@
1
- # coding: utf-8
2
-
3
- require 'spec_helper'
1
+ # frozen_string_literal: true
4
2
 
5
3
  RSpec.describe TTY::Table::Field, '#==' do
6
4
  let(:value) { '1' }
@@ -1,6 +1,4 @@
1
- # coding: utf-8
2
-
3
- require 'spec_helper'
1
+ # frozen_string_literal: true
4
2
 
5
3
  RSpec.describe TTY::Table::Field, '.length' do
6
4
  it "calculates length for nil string" do
@@ -1,6 +1,4 @@
1
- # coding: utf-8
2
-
3
- require 'spec_helper'
1
+ # frozen_string_literal: true
4
2
 
5
3
  RSpec.describe TTY::Table::Field, '#lines' do
6
4
  let(:object) { described_class.new value }
@@ -1,6 +1,4 @@
1
- # coding: utf-8
2
-
3
- require 'spec_helper'
1
+ # frozen_string_literal: true
4
2
 
5
3
  RSpec.describe TTY::Table::Field, '#new' do
6
4
  let(:object) { described_class }
@@ -1,6 +1,4 @@
1
- # encoding: utf-8
2
-
3
- require 'spec_helper'
1
+ # frozen_string_literal: true
4
2
 
5
3
  RSpec.describe TTY::Table::Field, '#width' do
6
4
  let(:object) { described_class }
@@ -1,6 +1,4 @@
1
- # coding: utf-8
2
-
3
- require 'spec_helper'
1
+ # frozen_string_literal: true
4
2
 
5
3
  RSpec.describe TTY::Table, '#filter' do
6
4
  let(:header) { ['h1', 'h2', 'h3'] }
@@ -1,6 +1,4 @@
1
- # coding: utf-8
2
-
3
- require 'spec_helper'
1
+ # frozen_string_literal: true
4
2
 
5
3
  RSpec.describe TTY::Table::Header, '#call' do
6
4
  let(:object) { described_class.new(attributes) }
@@ -1,6 +1,4 @@
1
- # coding: utf-8
2
-
3
- require 'spec_helper'
1
+ # frozen_string_literal: true
4
2
 
5
3
  RSpec.describe TTY::Table::Header, 'color' do
6
4
 
@@ -1,6 +1,4 @@
1
- # coding: utf-8
2
-
3
- require 'spec_helper'
1
+ # frozen_string_literal: true
4
2
 
5
3
  RSpec.describe TTY::Table::Header, '#==' do
6
4
  let(:attributes) { [:id, :name] }
@@ -1,6 +1,4 @@
1
- # coding: utf-8
2
-
3
- require 'spec_helper'
1
+ # frozen_string_literal: true
4
2
 
5
3
  RSpec.describe TTY::Table::Header, '#height' do
6
4
  let(:object) { described_class.new header }
@@ -1,9 +1,6 @@
1
- # coding: utf-8
2
-
3
- require 'spec_helper'
1
+ # frozen_string_literal: true
4
2
 
5
3
  RSpec.describe TTY::Table::Header, '#new' do
6
-
7
4
  it "is empty without arguments" do
8
5
  header = TTY::Table::Header.new
9
6
  expect(header).to be_empty
@@ -1,6 +1,4 @@
1
- # coding: utf-8
2
-
3
- require 'spec_helper'
1
+ # frozen_string_literal: true
4
2
 
5
3
  RSpec.describe TTY::Table::Header, '#set' do
6
4
  let(:object) { described_class }
@@ -1,6 +1,4 @@
1
- # encoding: utf-8
2
-
3
- require 'spec_helper'
1
+ # frozen_string_literal: true
4
2
 
5
3
  RSpec.describe TTY::Table::Header, '#to_ary' do
6
4
  let(:object) { described_class.new(attributes) }
@@ -1,6 +1,4 @@
1
- # coding: utf-8
2
-
3
- require 'spec_helper'
1
+ # frozen_string_literal: true
4
2
 
5
3
  RSpec.describe TTY::Table, '#header' do
6
4
  let(:header) { [:header1, :header2] }
@@ -1,6 +1,4 @@
1
- # coding: utf-8
2
-
3
- require 'spec_helper'
1
+ # frozen_string_literal: true
4
2
 
5
3
  RSpec.describe TTY::Table::Indentation, '.indent' do
6
4
  context 'when enumerable' do
@@ -1,6 +1,4 @@
1
- # coding: utf-8
2
-
3
- require 'spec_helper'
1
+ # frozen_string_literal: true
4
2
 
5
3
  RSpec.describe TTY::Table, '#new' do
6
4
  it { is_expected.to be_kind_of(Enumerable) }
@@ -1,6 +1,4 @@
1
- # coding: utf-8
2
-
3
- require 'spec_helper'
1
+ # frozen_string_literal: true
4
2
 
5
3
  RSpec.describe TTY::Table::Operation::Alignment, '#call' do
6
4
  let(:object) { described_class.new alignments, widths }
@@ -1,6 +1,4 @@
1
- # coding: utf-8
2
-
3
- require 'spec_helper'
1
+ # frozen_string_literal: true
4
2
 
5
3
  RSpec.describe TTY::Table::Operation::Escape, '#call' do
6
4
  let(:object) { described_class }
@@ -1,6 +1,4 @@
1
- # coding: utf-8
2
-
3
- require 'spec_helper'
1
+ # frozen_string_literal: true
4
2
 
5
3
  RSpec.describe TTY::Table::Operation::Filter, '#call' do
6
4
  let(:object) { described_class }
@@ -1,6 +1,4 @@
1
- # coding: utf-8
2
-
3
- require 'spec_helper'
1
+ # frozen_string_literal: true
4
2
 
5
3
  RSpec.describe TTY::Table::Operation::Truncation, '#call' do
6
4
  let(:text) { '太丸ゴシック体' }
@@ -1,6 +1,4 @@
1
- # coding: utf-8
2
-
3
- require 'spec_helper'
1
+ # frozen_string_literal: true
4
2
 
5
3
  RSpec.describe TTY::Table::Operation::Wrapped, '#call' do
6
4
  let(:text) { 'ラドクリフ、マラソン五輪代表に1万m出場にも含み' }
@@ -1,4 +1,4 @@
1
- # coding: utf-8
1
+ # frozen_string_literal: true
2
2
 
3
3
  RSpec.describe TTY::Table::Operations, '#new' do
4
4
  let(:object) { described_class }
@@ -1,6 +1,4 @@
1
- # coding: utf-8
2
-
3
- require 'spec_helper'
1
+ # frozen_string_literal: true
4
2
 
5
3
  # describe TTY::Table::Options, 'options' do
6
4
  # let(:object) { described_class }
@@ -1,6 +1,4 @@
1
- # coding: utf-8
2
-
3
- require 'spec_helper'
1
+ # frozen_string_literal: true
4
2
 
5
3
  RSpec.describe TTY::Table, 'options' do
6
4
  let(:rows) { [['a1', 'a2'], ['b1', 'b2']] }
@@ -1,6 +1,4 @@
1
- # coding: utf-8
2
-
3
- require 'spec_helper'
1
+ # frozen_string_literal: true
4
2
 
5
3
  RSpec.describe TTY::Table, 'orientation' do
6
4
  let(:header) { ['h1', 'h2', 'h3'] }
@@ -1,6 +1,4 @@
1
- # encoding: utf-8
2
-
3
- require 'spec_helper'
1
+ # frozen_string_literal: true
4
2
 
5
3
  RSpec.describe TTY::Table, 'padding' do
6
4
  let(:header) { ['h1', 'h2', 'h3'] }
@@ -1,6 +1,4 @@
1
- # coding: utf-8
2
-
3
- require 'spec_helper'
1
+ # frozen_string_literal: true
4
2
 
5
3
  RSpec.describe TTY::Table, 'properties' do
6
4
  let(:rows) {[['a1', 'a2', 'a3'], ['b1', 'b2', 'c3']] }
@@ -1,9 +1,6 @@
1
- # coding: utf-8
2
-
3
- require 'spec_helper'
1
+ # frozen_string_literal: true
4
2
 
5
3
  RSpec.describe TTY::Table, 'render repeat' do
6
-
7
4
  it "renders consistently" do
8
5
  table = TTY::Table.new header: ['header1', 'header2']
9
6
  table << ['a1', 'a2']
@@ -1,6 +1,4 @@
1
- # coding: utf-8
2
-
3
- require 'spec_helper'
1
+ # frozen_string_literal: true
4
2
 
5
3
  RSpec.describe TTY::Table, '#render' do
6
4
  let(:object) { described_class }
@@ -1,6 +1,4 @@
1
- # coding: utf-8
2
-
3
- require 'spec_helper'
1
+ # frozen_string_literal: true
4
2
 
5
3
  RSpec.describe TTY::Table, '#render_with' do
6
4
  let(:header) { ['h1', 'h2', 'h3'] }
@@ -1,6 +1,4 @@
1
- # coding: utf-8
2
-
3
- require 'spec_helper'
1
+ # frozen_string_literal: true
4
2
 
5
3
  RSpec.describe TTY::Table::Renderer::ASCII, 'coloring' do
6
4
 
@@ -66,5 +64,20 @@ RSpec.describe TTY::Table::Renderer::ASCII, 'coloring' do
66
64
  +-------+-------+
67
65
  EOS
68
66
  end
67
+
68
+ xit "colors adjecent content" do
69
+ hello = color.decorate("hello", :black, :on_green)
70
+ world = color.decorate("world", :black, :on_red)
71
+
72
+ table = TTY::Table.new [:header], [
73
+ [hello],
74
+ [world],
75
+ [hello + world],
76
+ [hello + ' ' + world],
77
+ ]
78
+ renderer = described_class.new(table, column_widths: 6, multiline: true)
79
+
80
+ rendered = renderer.render
81
+ end
69
82
  end
70
83
  end
@@ -1,6 +1,4 @@
1
- # coding: utf-8
2
-
3
- require 'spec_helper'
1
+ # frozen_string_literal: true
4
2
 
5
3
  RSpec.describe TTY::Table::Renderer::ASCII, 'indentation' do
6
4
  let(:header) { ['h1', 'h2', 'h3'] }
@@ -1,6 +1,4 @@
1
- # coding: utf-8
2
-
3
- require 'spec_helper'
1
+ # frozen_string_literal: true
4
2
 
5
3
  RSpec.describe TTY::Table::Renderer::ASCII, 'multiline content' do
6
4
  context 'with escaping' do
@@ -1,6 +1,4 @@
1
- # coding: utf-8
2
-
3
- require 'spec_helper'
1
+ # frozen_string_literal: true
4
2
 
5
3
  RSpec.describe TTY::Table::Renderer::ASCII, 'padding' do
6
4
  let(:header) { ['Field', 'Type', 'Null', 'Key', 'Default', 'Extra'] }
@@ -1,6 +1,4 @@
1
- # coding: utf-8
2
-
3
- require 'spec_helper'
1
+ # frozen_string_literal: true
4
2
 
5
3
  RSpec.describe TTY::Table::Renderer::ASCII, '#render' do
6
4
  let(:header) { ['h1', 'h2', 'h3'] }
@@ -1,6 +1,4 @@
1
- # coding: utf-8
2
-
3
- require 'spec_helper'
1
+ # frozen_string_literal: true
4
2
 
5
3
  RSpec.describe TTY::Table::Renderer::ASCII, 'resizing' do
6
4
  let(:header) { ['h1', 'h2', 'h3'] }
@@ -1,6 +1,4 @@
1
- # coding: utf-8
2
-
3
- require 'spec_helper'
1
+ # frozen_string_literal: true
4
2
 
5
3
  RSpec.describe TTY::Table::Renderer::ASCII, 'with separator' do
6
4
  let(:header) { ['h1', 'h2', 'h3'] }
@@ -13,7 +11,7 @@ RSpec.describe TTY::Table::Renderer::ASCII, 'with separator' do
13
11
 
14
12
  context 'when ascii' do
15
13
  it "renders each row" do
16
- renderer.border.separator= :each_row
14
+ renderer.border.separator = :each_row
17
15
  expect(renderer.render).to eq unindent(<<-EOS)
18
16
  +--+--+--+
19
17
  |h1|h2|h3|
@@ -24,5 +22,17 @@ RSpec.describe TTY::Table::Renderer::ASCII, 'with separator' do
24
22
  +--+--+--+
25
23
  EOS
26
24
  end
25
+
26
+ it "will not the default separator if individual separators are specified" do
27
+ renderer.border.separator = [1]
28
+ expect(renderer.render).to eq unindent(<<-EOS)
29
+ +--+--+--+
30
+ |h1|h2|h3|
31
+ |a1|a2|a3|
32
+ +--+--+--+
33
+ |b1|b2|b3|
34
+ +--+--+--+
35
+ EOS
36
+ end
27
37
  end
28
38
  end