tebako 0.5.2 → 0.5.3

Sign up to get free protection for your applications and to get access to all the features.
Files changed (74) hide show
  1. checksums.yaml +4 -4
  2. data/CMakeLists.txt +21 -29
  3. data/README.adoc +53 -28
  4. data/Rakefile +1 -1
  5. data/common.env +1 -1
  6. data/lib/tebako/cli.rb +23 -0
  7. data/lib/tebako/cli_helpers.rb +3 -3
  8. data/lib/tebako/packager/pass1.rb +3 -1
  9. data/lib/tebako/packager/pass2.rb +64 -274
  10. data/{tests-2/fixtures/gems-expressir/gems-expressir.rb → lib/tebako/packager/patch_helpers.rb} +30 -5
  11. data/lib/tebako/packager/patch_literals.rb +255 -0
  12. data/lib/tebako/version.rb +1 -1
  13. data/tebako.gemspec +1 -1
  14. data/version.txt +1 -1
  15. metadata +4 -62
  16. data/tests/scripts/cross-tests.sh +0 -34
  17. data/tests/scripts/functional-tests.sh +0 -335
  18. data/tests/test-00/test.rb +0 -4
  19. data/tests/test-01/tebako-test-run.rb +0 -5
  20. data/tests/test-09/tebako-test-0.0.1.gem +0 -0
  21. data/tests/test-11/bin/tebako-test-run.rb +0 -10
  22. data/tests/test-11/lib/tebako-test.rb +0 -20
  23. data/tests/test-11/tebako-test.gemspec +0 -15
  24. data/tests/test-12/tebako-test-a.gemspec +0 -15
  25. data/tests/test-12/tebako-test-b.gemspec +0 -15
  26. data/tests/test-13/bin/tebako-test-run.rb +0 -10
  27. data/tests/test-13/lib/tebako-test.rb +0 -20
  28. data/tests/test-13/tebako-test.gemspec +0 -15
  29. data/tests/test-15/Gemfile +0 -8
  30. data/tests/test-15/Rakefile +0 -4
  31. data/tests/test-15/bin/tebako-test-run.rb +0 -10
  32. data/tests/test-15/lib/tebako/bundle/test/version.rb +0 -9
  33. data/tests/test-15/lib/tebako/bundle/test.rb +0 -29
  34. data/tests/test-15/tebako-bundle-test.gemspec +0 -30
  35. data/tests/test-16/Gemfile +0 -8
  36. data/tests/test-16/Rakefile +0 -4
  37. data/tests/test-16/bin/tebako-test-run.rb +0 -10
  38. data/tests/test-16/lib/tebako/bundle/test/version.rb +0 -9
  39. data/tests/test-16/lib/tebako/bundle/test.rb +0 -29
  40. data/tests/test-16/tebako-bundle-test.gemspec +0 -24
  41. data/tests/test-18/Gemfile +0 -5
  42. data/tests/test-18/tebako-test-run.rb +0 -12
  43. data/tests/test-19/Gemfile +0 -6
  44. data/tests/test-19/tebako-test-run.rb +0 -11
  45. data/tests-2/fixtures/gems-bundler/Gemfile +0 -4
  46. data/tests-2/fixtures/gems-bundler/gems-bundler.rb +0 -34
  47. data/tests-2/fixtures/gems-byebug/Gemfile +0 -5
  48. data/tests-2/fixtures/gems-byebug/gems-byebug.rb +0 -31
  49. data/tests-2/fixtures/gems-expressir/Gemfile +0 -7
  50. data/tests-2/fixtures/gems-libmspack/Gemfile +0 -5
  51. data/tests-2/fixtures/gems-libmspack/gems-libmspack.rb +0 -91
  52. data/tests-2/fixtures/gems-sassc/Gemfile +0 -6
  53. data/tests-2/fixtures/gems-sassc/base_style/all.scss +0 -1
  54. data/tests-2/fixtures/gems-sassc/base_style/reset.scss +0 -100
  55. data/tests-2/fixtures/gems-sassc/gems-sassc.rb +0 -129
  56. data/tests-2/fixtures/gems-seven-zip/Gemfile +0 -7
  57. data/tests-2/fixtures/gems-seven-zip/gems-seven-zip.rb +0 -53
  58. data/tests-2/fixtures/launcher-coreincl/launcher-coreincl.rb +0 -29
  59. data/tests-2/fixtures/launcher-package/launcher-package.rb +0 -29
  60. data/tests-2/fixtures/launcher-pwd/launcher-pwd.rb +0 -28
  61. data/tests-2/fixtures/launcher-stdinredir/input.txt +0 -1
  62. data/tests-2/fixtures/launcher-stdinredir/launcher-stdinredir.rb +0 -31
  63. data/tests-2/fixtures/launcher-stdoutredir/launcher-stdoutredir.rb +0 -28
  64. data/tests-2/fixtures/patches-dir/level-1/level-2/file-1.txt +0 -1
  65. data/tests-2/fixtures/patches-dir/level-1/level-2/file-2.txt +0 -1
  66. data/tests-2/fixtures/patches-dir/level-1/level-2/file-3.txt +0 -1
  67. data/tests-2/fixtures/patches-dir/patches-dir.rb +0 -154
  68. data/tests-2/fixtures/patches-io-and-file/level-1/level-2/file-1.txt +0 -1
  69. data/tests-2/fixtures/patches-io-and-file/level-1/level-2/file-2.txt +0 -2
  70. data/tests-2/fixtures/patches-io-and-file/level-1/level-2/file-3.txt +0 -1
  71. data/tests-2/fixtures/patches-io-and-file/level-1/link-3 +0 -1
  72. data/tests-2/fixtures/patches-io-and-file/patches-io-and-file.rb +0 -87
  73. data/tests-2/fixtures/patches-main/patches-main.rb +0 -6
  74. data/tests-2/tebako-test.rb +0 -313
@@ -1,335 +0,0 @@
1
- #! /bin/bash
2
- #
3
- # Copyright (c) 2021, [Ribose Inc](https://www.ribose.com).
4
- # All rights reserved.
5
- # This file is a part of tebako
6
- #
7
- # Redistribution and use in source and binary forms, with or without
8
- # modification, are permitted provided that the following conditions
9
- # are met:
10
- # 1. Redistributions of source code must retain the above copyright
11
- # notice, this list of conditions and the following disclaimer.
12
- # 2. Redistributions in binary form must reproduce the above copyright
13
- # notice, this list of conditions and the following disclaimer in the
14
- # documentation and/or other materials provided with the distribution.
15
- #
16
- # THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
17
- # ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
18
- # TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
19
- # PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS
20
- # BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
21
- # CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
22
- # SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
23
- # INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
24
- # CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
25
- # ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
26
- # POSSIBILITY OF SUCH DAMAGE.
27
-
28
- # ......................................................................
29
- # Helper functions
30
- press_runner() {
31
- # Runs 'tabako press'
32
- # Parameters:
33
- # $1 -- project root
34
- # $2 -- entry point
35
- # $3 -- tebako package name
36
- if [ "${VERBOSE}" == "yes" ]; then
37
- "$DIR_BIN"/tebako press -R "$RUBY_VER" --root="$1" --entry-point="$2" --output="$3" 2>&1 | tee tebako_test.log
38
- assertEquals 0 "${PIPESTATUS[0]}"
39
- result="$( cat tebako_test.log )"
40
- else
41
- result=$( "$DIR_BIN"/tebako press -R "$RUBY_VER" --root="$1" --entry-point="$2" --output="$3" 2>&1 )
42
- assertEquals 0 $?
43
- fi
44
-
45
- # Check the first and the last messages expected from CMake script
46
- assertContains "$result" "Running tebako press script"
47
- assertContains "$result" "packaging has completed"
48
- }
49
-
50
- package_runner() {
51
- # Runs a package built by tebako
52
- # Parameters:
53
- # $1 -- file name
54
- # $2 -- expected output
55
- if [ "${VERBOSE}" == "yes" ]; then
56
- $1 | tee tebako_test.log
57
- assertEquals 0 "${PIPESTATUS[0]}"
58
- result="$( cat tebako_test.log )"
59
- else
60
- result="$( $1 )"
61
- assertEquals 0 $?
62
- fi
63
-
64
- assertContains "$result" "$2"
65
- }
66
-
67
- press_runner_with_error() {
68
- # Runs 'tabako press' expecting failure
69
- # Parameters:
70
- # $1 -- project root
71
- # $2 -- entry point
72
- # $3 -- tebako package name
73
- # $4 -- expected error code
74
- # $5 -- expected error message
75
- if [ "${VERBOSE}" == "yes" ]; then
76
- "$DIR_BIN"/tebako press -R "$RUBY_VER" --root="$1" --entry-point="$2" --output="$3" 2>&1 | tee tebako_test.log
77
- assertEquals "$4" "${PIPESTATUS[0]}"
78
- result="$( cat tebako_test.log )"
79
- else
80
- result=$( "$DIR_BIN"/tebako press -R "$RUBY_VER" --root="$1" --entry-point="$2" --output="$3" 2>&1 )
81
- assertEquals "$4" "${PIPESTATUS[0]}"
82
- fi
83
-
84
- assertContains "$result" "Running tebako press script"
85
- assertContains "$result" "$5"
86
- }
87
-
88
- # ......................................................................
89
- # Tests
90
- # 00. Basic tebako CLI tests (error handling)
91
- # -- tebako setup [commented out, redundant]
92
- # AU. Check that it is possible to extract image content (--tebako-extract option)
93
- # 01. Simple Ruby script, absolute path to root, relative path to entry point
94
- # 02. Simple Ruby script, absolute path to root, relative path to entry point, entry point does not exist [Expected error at build step]
95
- # 03. Simple Ruby script, absolute path to root, absolute path to entry point
96
- # 04. Simple Ruby script, relative path to root, relative path to entry point
97
- # 05. Simple Ruby script, absolute path to root absolute path to entry point, entry point not within root [Expected error at configure step]
98
- # 09. Ruby gem (xxx.gem, no gemspec, no gemfile)
99
- # 10. Ruby gem (xxx.gem, no gemspec, no gemfile), entry point does not exist [Expected error at build step]
100
- # 11. Ruby gem (no gemfile, with gemspec)
101
- # 12. Ruby gem (no gemfile, with gemspec), multiple gemspecs [Expected error at configure step]
102
- # 13. Ruby gem (no gemfile, with gemspec), gemspec error [Expected error at build step]
103
- # 14. Ruby gem (no gemfile, with gemspec), entry point does not exist [Expected error at build step]
104
- # 15. Ruby gem (with gemspec, with gemfile)
105
- # 16. Ruby gem (with gemspec, with gemfile), gemfile with error [Expected error at build step]
106
- # 17. Ruby gem (with gemspec, with gemfile), entry point does not exist [Expected error at build step]
107
- # 18. Ruby project (no gemspec, with gemfile)
108
- # 19. Ruby project (no gemspec, with gemfile, with native extension)
109
-
110
- # ......................................................................
111
- # 00. Very basic tebako CLI tests (error handling)
112
- test_CLI_help() {
113
- result=$( "$DIR_BIN"/tebako help )
114
-
115
- assertEquals 0 "${PIPESTATUS[0]}"
116
- assertContains "$result" "Tebako commands:"
117
- }
118
-
119
- test_CLI_missing_command() {
120
- result=$( "$DIR_BIN"/tebako )
121
-
122
- assertEquals 0 "${PIPESTATUS[0]}"
123
- assertContains "$result" "Tebako commands:"
124
- }
125
-
126
- test_CLI_unknown_command() {
127
- result=$( "$DIR_BIN"/tebako jump 2>&1)
128
-
129
- assertEquals 1 "${PIPESTATUS[0]}"
130
- assertContains "$result" "Could not find command"
131
- }
132
-
133
- test_CLI_no_root() {
134
- result=$( "$DIR_BIN"/tebako press -R "$RUBY_VER" --entry-point=tebako-test-run.rb --output=test-00-package 2>&1 )
135
-
136
- assertEquals 1 "${PIPESTATUS[0]}"
137
- assertContains "$result" "No value provided for required options '--root'"
138
- }
139
-
140
- test_CLI_no_entry_point() {
141
- result=$( "$DIR_BIN"/tebako press -R "$RUBY_VER" --root=tests/test-00 --output=test-00-package 2>&1 )
142
-
143
- assertEquals 1 "${PIPESTATUS[0]}"
144
- assertContains "$result" "No value provided for required options '--entry-point'"
145
- }
146
-
147
- test_CLI_invalid_Ruby_version() {
148
- result=$( "$DIR_BIN"/tebako press --root=tests/test-00 --output=test-00-package --entry-point=tebako-test-run.rb --Ruby=1.9.3 2>&1 )
149
-
150
- assertEquals 1 "${PIPESTATUS[0]}"
151
- assertContains "$result" "Expected '--Ruby' to be one of"
152
- }
153
-
154
-
155
- # ......................................................................
156
- # -- tebako setup
157
- #test_tebako_setup() {
158
- # echo "tebako setup ... patience, please, it may take up to 1 hour."
159
- # if [ "${VERBOSE}" == "yes" ]; then
160
- # "$DIR_BIN"/tebako setup -R "$RUBY_VER" 2>&1 | tee tebako_test.log
161
- # assertEquals 0 "${PIPESTATUS[0]}"
162
- # result="$( cat tebako_test.log )"
163
- # else
164
- # result=$( "$DIR_BIN"/tebako setup -R "$RUBY_VER" 2>&1 )
165
- # assertEquals 0 "${PIPESTATUS[0]}"
166
- # fi
167
-
168
- # Check the first and the last messages expected from CMake script
169
- # assertContains "$result" "Running tebako setup script"
170
- # assertContains "$result" "Tebako setup has completed"
171
- #}
172
-
173
- # ......................................................................
174
- # AU. Check that it is possible to extract image content (--tebako-extract option)
175
- test_AUC_extract() {
176
- echo "==> Check --tebako-extract option"
177
- result=$( "$DIR_BIN"/tebako press -R "$RUBY_VER" --root=tests/test-01 --entry=tebako-test-run.rb --output=test-AUC-package 2>&1 )
178
-
179
- assertEquals 0 "${PIPESTATUS[0]}"
180
- assertContains "$result" "Running tebako press script"
181
- assertContains "$result" "packaging has completed"
182
-
183
- ./test-AUC-package --tebako-extract
184
- assertEquals 0 "${PIPESTATUS[0]}"
185
-
186
- diff -r source_filesystem output/source_filesystem
187
- assertEquals 0 "${PIPESTATUS[0]}"
188
-
189
- rm -rf source_filesystem
190
-
191
- ./test-AUC-package --tebako-extract extract
192
- assertEquals 0 "${PIPESTATUS[0]}"
193
-
194
- diff -r extract output/source_filesystem
195
- assertEquals 0 "${PIPESTATUS[0]}"
196
-
197
- rm -rf extract
198
- }
199
-
200
- # ......................................................................
201
- # 01. Simple Ruby script, absolute path to root, relative path to entry point
202
- test_tebako_press_01() {
203
- echo "==> simple Ruby script, absolute path to root, relative path to entry point"
204
- press_runner "${DIR_TESTS}/test-01" "tebako-test-run.rb" "test-01-package"
205
- package_runner "./test-01-package" "Hello! This is test-1 talking from inside DwarFS"
206
- }
207
-
208
- # ......................................................................
209
- # 02. Simple Ruby script, absolute path to root, relative path to entry point, entry point does not exist
210
- test_tebako_press_02() {
211
- echo "==> simple Ruby script, absolute path to root, relative path to entry point, entry point does not exist"
212
- press_runner_with_error "${DIR_TESTS}/test-01" "test-does-not-exist.rb" "test-02-package" 104 "'tebako press' build step failed"
213
- }
214
-
215
- # ......................................................................
216
- # 03. Simple Ruby script, absolute path to root, absolute path to entry point
217
- test_tebako_press_03() {
218
- echo "==> simple Ruby script, absolute path to root, absolute path to entry point"
219
- press_runner "${DIR_TESTS}/test-01" "${DIR_TESTS}/test-01/tebako-test-run.rb" "test-03-package"
220
- package_runner "./test-03-package" "Hello! This is test-1 talking from inside DwarFS"
221
- }
222
-
223
- # ......................................................................
224
- # 04. Simple Ruby script, relative path to root, relative path to entry point
225
- test_tebako_press_04() {
226
- echo "==> simple Ruby script, relative path to root, relative path to entry point"
227
- pushd "${DIR_ROOT}" > /dev/null || fail "pushd ${DIR_ROOT} failed"
228
- press_runner "tests/test-01" "tebako-test-run.rb" "test-04-package"
229
- package_runner "./test-04-package" "Hello! This is test-1 talking from inside DwarFS"
230
- popd > /dev/null || fail "popd failed"
231
- }
232
-
233
- # ......................................................................
234
- # 05. Simple Ruby script, absolute path to root absolute path to entry point, entry point not within root
235
- test_tebako_press_05() {
236
- echo "==> simple Ruby script, absolute path to root absolute path to entry point, not within root"
237
- press_runner_with_error "${DIR_TESTS}/test-01" "${DIR_TESTS}/test-00/test.rb" "test-05-package" 103 "'tebako press' configure step failed"
238
- }
239
-
240
- # ......................................................................
241
- # 09. Ruby gem (xxx.gem, no gemspec, no gemfile)
242
- test_tebako_press_09() {
243
- echo "==> Ruby gem (xxx.gem, no gemspec, no gemfile)"
244
- press_runner "${DIR_TESTS}/test-09" "tebako-test-run.rb" "test-09-package"
245
- package_runner "./test-09-package" "| a1 | b1 |"
246
- }
247
-
248
- # ......................................................................
249
- # 10. Ruby gem (xxx.gem, no gemspec, no gemfile), entry point does not exist
250
- test_tebako_press_10() {
251
- echo "==> Ruby gem (xxx.gem, no gemspec, no gemfile), entry point does not exist"
252
- press_runner_with_error "${DIR_TESTS}/test-09" "test-does-not-exist.rb" "test-10-package" 104 "'tebako press' build step failed"
253
- }
254
-
255
- # ......................................................................
256
- # 11. Ruby gem (no gemfile, with gemspec)
257
- test_tebako_press_11() {
258
- echo "==> Ruby gem (no gemfile, with gemspec)"
259
- press_runner "${DIR_TESTS}/test-11" "tebako-test-run.rb" "test-11-package"
260
- package_runner "./test-11-package" "| a1 | b1 |"
261
- }
262
-
263
- # ......................................................................
264
- # 12. Ruby gem (no gemfile, with gemspec), multiple gemspecs
265
- test_tebako_press_12() {
266
- echo "==> Ruby gem (no gemfile, with gemspec), multiple gemspecs"
267
- press_runner_with_error "${DIR_TESTS}/test-12" "tebako-test-run.rb" "test-12-package" 103 "'tebako press' configure step failed"
268
- }
269
-
270
- # ......................................................................
271
- # 13. Ruby gem (no gemfile, with gemspec), gemspec error
272
- test_tebako_press_13() {
273
- echo "==> Ruby gem (no gemfile, with gemspec), gemspec error"
274
- press_runner_with_error "${DIR_TESTS}/test-13" "tebako-test-run.rb" "test-13-package" 104 "'tebako press' build step failed"
275
- }
276
-
277
- # ......................................................................
278
- # 14. Ruby gem (no gemfile, with gemspec), entry point does not exist
279
- test_tebako_press_14() {
280
- echo "==> Ruby gem (no gemfile, with gemspec), entry point does not exist"
281
- press_runner_with_error "${DIR_TESTS}/test-14" "test-does-not-exist.rb" "test-14-package" 104 "'tebako press' build step failed"
282
- }
283
-
284
- # ......................................................................
285
- # 15. Ruby gem (with gemspec, with gemfile)
286
- test_tebako_press_15() {
287
- echo "==> Ruby gem (with gemspec, with gemfile)"
288
- press_runner "${DIR_TESTS}/test-15" "tebako-test-run.rb" "test-15-package"
289
- package_runner "./test-15-package" "| a1 | b1 |"
290
- }
291
-
292
- # ......................................................................
293
- # 16. Ruby gem (with gemspec, with gemfile), gemfile with error
294
- test_tebako_press_16() {
295
- echo "==> Ruby gem (with gemspec, with gemfile), gemfile with error"
296
- press_runner_with_error "${DIR_TESTS}/test-16" "tebako-test-run.rb" "test-16-package" 104 "'tebako press' build step failed"
297
- }
298
-
299
- # ......................................................................
300
- # 17. Ruby gem (with gemspec, with gemfile), entry point dows not exist
301
- test_tebako_press_17() {
302
- echo "==> Ruby gem (with gemspec, with gemfile), entry point does not exist"
303
- press_runner_with_error "${DIR_TESTS}/test-15" "test-does-not-exist.rb" "test-17-package" 104 "'tebako press' build step failed"
304
- }
305
-
306
- # ......................................................................
307
- # 18. Ruby project (no gemspec, with gemfile)
308
- test_tebako_press_18() {
309
- echo "==> Ruby project (no gemspec, with gemfile)"
310
- press_runner "${DIR_TESTS}/test-18" "tebako-test-run.rb" "test-18-package"
311
- package_runner "./test-18-package" "| a1 | b1 |"
312
- }
313
-
314
- # ......................................................................
315
- # 19. Ruby project (no gemspec, with gemfile, with native extension)
316
- test_tebako_press_19() {
317
- if [[ "$OSTYPE" != "msys" ]]; then
318
- echo "==> Ruby project (no gemspec, with gemfile, with native extension)"
319
- press_runner "${DIR_TESTS}/test-19" "tebako-test-run.rb" "test-19-package"
320
- package_runner "./test-19-package" "Hello, World via libc puts using FFI on tebako package"
321
- fi
322
- }
323
-
324
- # ......................................................................
325
- # main
326
-
327
- DIR0=$( dirname "$0" )
328
- DIR_ROOT=$( cd "$DIR0"/../.. && pwd )
329
- DIR_BIN=$( cd "$DIR_ROOT"/exe && pwd )
330
- DIR_TESTS=$( cd "$DIR_ROOT"/tests && pwd )
331
- RUBY_VER=${RUBY_VER:-3.0.6}
332
-
333
- echo "Running tebako tests"
334
- # shellcheck source=/dev/null
335
- . "$DIR_TESTS/shunit2/shunit2"
@@ -1,4 +0,0 @@
1
- #!/home/tebako/bin/ruby
2
- # frozen_string_literal: true
3
-
4
- puts "Hello! This is test-1 talking from inside DwarFS"
@@ -1,5 +0,0 @@
1
- #!/home/tebako/bin/ruby
2
- # frozen_string_literal: true
3
-
4
- puts "Hello! This is test-1 talking from inside DwarFS"
5
- puts "Gem path: #{Gem.path}"
Binary file
@@ -1,10 +0,0 @@
1
- #!/home/tebako/bin/ruby
2
- # frozen_string_literal: true
3
-
4
- $LOAD_PATH.unshift File.expand_path("../lib", __dir__)
5
- require "tebako-test"
6
-
7
- begin
8
- instance = TebakoTest.new
9
- instance.run!
10
- end
@@ -1,20 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- require "text-table"
4
-
5
- # Tebako test class
6
- class TebakoTest
7
- def msg
8
- table = Text::Table.new
9
- table.head = %w[A B]
10
- table.rows = [%w[a1 b1]]
11
- table.rows << %w[a2 b2]
12
- puts table
13
- end
14
-
15
- def run!
16
- puts "Hello! This is test-11 talking from inside DwarFS"
17
- puts "You will now see a nice table that will be drawn for you by text-table gem."
18
- msg
19
- end
20
- end
@@ -1,15 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- Gem::Specification.new do |s|
4
- s.name = "tebako-test"
5
- s.version = "0.0.1"
6
- s.summary = "A simple gem for tebako testing"
7
- s.authors = ["Ribose"]
8
- s.email = ["open.source@ribose.com"]
9
- s.files = ["bin/tebako-test-run.rb", "lib/tebako-test.rb"]
10
- s.homepage = "https://github.com/tamitebako"
11
- s.license = "Unlicense"
12
- s.required_ruby_version = Gem::Requirement.new(">= 2.7.0")
13
- s.add_dependency "text-table", "~> 1.2.4"
14
- s.executables << "tebako-test-run.rb"
15
- end
@@ -1,15 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- Gem::Specification.new do |s|
4
- s.name = "tebako-test"
5
- s.version = "0.0.1"
6
- s.summary = "A simple gem for tebako testing"
7
- s.authors = ["Ribose"]
8
- s.email = ["open.source@ribose.com"]
9
- s.files = ["bin/tebako-test-run.rb", "lib/tebako-test.rb"]
10
- s.homepage = "https://github.com/tamitebako"
11
- s.license = "Unlicense"
12
- s.required_ruby_version = Gem::Requirement.new(">= 2.7.0")
13
- s.add_dependency "text-table", "~> 1.2.4"
14
- s.executables << "tebako-test-run.rb"
15
- end
@@ -1,15 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- Gem::Specification.new do |s|
4
- s.name = "tebako-test"
5
- s.version = "0.0.1"
6
- s.summary = "A simple gem for tebako testing"
7
- s.authors = ["Ribose"]
8
- s.email = ["open.source@ribose.com"]
9
- s.files = ["bin/tebako-test-run.rb", "lib/tebako-test.rb"]
10
- s.homepage = "https://github.com/tamitebako"
11
- s.license = "Unlicense"
12
- s.required_ruby_version = Gem::Requirement.new(">= 2.7.0")
13
- s.add_dependency "text-table", "~> 1.2.4"
14
- s.executables << "tebako-test-run.rb"
15
- end
@@ -1,10 +0,0 @@
1
- #!/home/tebako/bin/ruby
2
- # frozen_string_literal: true
3
-
4
- $LOAD_PATH.unshift File.expand_path("../lib", __dir__)
5
- require "tebako-test"
6
-
7
- begin
8
- instance = TebakoTest.new
9
- instance.run!
10
- end
@@ -1,20 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- require "text-table"
4
-
5
- # Tebako test class
6
- class TebakoTest
7
- def msg
8
- table = Text::Table.new
9
- table.head = %w[A B]
10
- table.rows = [%w[a1 b1]]
11
- table.rows << %w[a2 b2]
12
- puts table
13
- end
14
-
15
- def run!
16
- puts "Hello! This is test-11 talking from inside DwarFS"
17
- puts "You will now see a nice table that will be drawn for you by text-table gem."
18
- msg
19
- end
20
- end
@@ -1,15 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- Gem::Specification.new do |s|
4
- s.name = "tebako-test"
5
- s.version = "0.0.1"
6
- s.summary = "A simple gem for tebako testing"
7
- s.authors = ["Ribose"]
8
- s.email = open.source @ribose.com
9
- s.files = ["bin/tebako-test-run.rb", "lib/tebako-test.rb"]
10
- s.homepage = "https://github.com/tamitebako"
11
- s.license = "Unlicense"
12
- s.required_ruby_version = Gem::Requirement.new(">= 2.7.0")
13
- s.add_dependency "text-table", "~> 1.2.4"
14
- s.executables << "tebako-test-run.rb"
15
- end
@@ -1,8 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- source "https://rubygems.org"
4
-
5
- # Specify your gem's dependencies in tebako-bundle-test.gemspec
6
- gemspec
7
-
8
- # gem "rake", "~> 13.0"
@@ -1,4 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- require "bundler/gem_tasks"
4
- task default: %i[]
@@ -1,10 +0,0 @@
1
- #!/home/tebako/bin/ruby
2
- # frozen_string_literal: true
3
-
4
- $LOAD_PATH.unshift File.expand_path("../lib/tebako/bundle", __dir__)
5
- require "test"
6
-
7
- begin
8
- instance = Tebako::Bundle::Test::TebakoTest.new
9
- instance.run!
10
- end
@@ -1,9 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- module Tebako
4
- module Bundle
5
- module Test
6
- VERSION = "0.0.1"
7
- end
8
- end
9
- end
@@ -1,29 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- require "text-table"
4
- require_relative "test/version"
5
-
6
- module Tebako
7
- module Bundle
8
- module Test
9
- class Error < StandardError; end
10
-
11
- # Tebako test class
12
- class TebakoTest
13
- def msg
14
- table = Text::Table.new
15
- table.head = %w[A B]
16
- table.rows = [%w[a1 b1]]
17
- table.rows << %w[a2 b2]
18
- puts table
19
- end
20
-
21
- def run!
22
- puts "Hello! This is test-15 talking from inside DwarFS"
23
- puts "You will now see a nice table that will be drawn for you by text-table gem."
24
- msg
25
- end
26
- end
27
- end
28
- end
29
- end
@@ -1,30 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- require_relative "lib/tebako/bundle/test/version"
4
-
5
- Gem::Specification.new do |spec|
6
- spec.name = "tebako-bundle-test"
7
- spec.version = Tebako::Bundle::Test::VERSION
8
- spec.authors = ["Ribose"]
9
- spec.email = ["open.source@ribose.com"]
10
-
11
- spec.summary = "A simple gem for tebako testing"
12
- spec.homepage = "https://github.com/tamitebako"
13
- spec.license = "Unlicense"
14
- spec.required_ruby_version = Gem::Requirement.new(">= 2.7.0")
15
- spec.metadata["homepage_uri"] = spec.homepage
16
-
17
- # Specify which files should be added to the gem when it is released.
18
- # The `git ls-files -z` loads the files in the RubyGem that have been added into git.
19
- # spec.files = Dir.chdir(File.expand_path(__dir__)) do
20
- # `git ls-files -z`.split("\x0").reject { |f| f.match(%r{\A(?:test|spec|features)/}) }
21
- # end
22
-
23
- spec.files = Dir["bin/**/*.rb"] + Dir["lib/**/*.rb"]
24
-
25
- spec.bindir = "bin"
26
- spec.executables << "tebako-test-run.rb"
27
- spec.require_paths = %w[bin lib]
28
-
29
- spec.add_dependency "text-table", "~> 1.2.4"
30
- end
@@ -1,8 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- source "https://rubygems.org"
4
-
5
- # Specify your gem's dependencies in tebako-bundle-test.gemspec
6
- gemspec
7
-
8
- gem "rake", "~> 13.0"
@@ -1,4 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- require "bundler/gem_tasks"
4
- task default: %i[]
@@ -1,10 +0,0 @@
1
- #!/home/tebako/bin/ruby
2
- # frozen_string_literal: true
3
-
4
- $LOAD_PATH.unshift File.expand_path("../lib/tebako/bundle", __dir__)
5
- require "test"
6
-
7
- begin
8
- instance = TebakoTest.new
9
- instance.run!
10
- end
@@ -1,9 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- module Tebako
4
- module Bundle
5
- module Test
6
- VERSION = "0.0.1"
7
- end
8
- end
9
- end
@@ -1,29 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- require "text-table"
4
- require_relative "test/version"
5
-
6
- module Tebako
7
- module Bundle
8
- module Test
9
- class Error < StandardError; end
10
-
11
- # Tebako test class
12
- class TebakoTest
13
- def msg
14
- table = Text::Table.new
15
- table.head = %w[A B]
16
- table.rows = [%w[a1 b1]]
17
- table.rows << %w[a2 b2]
18
- puts table
19
- end
20
-
21
- def run!
22
- puts "Hello! This is test-15 talking from inside DwarFS"
23
- puts "You will now see a nice table that will be drawn for you by text-table gem."
24
- msg
25
- end
26
- end
27
- end
28
- end
29
- end