rabbit-slide-kou-rubykaigi-2015 2015.12.12.2 → 2015.12.12.3
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 97452a242dfd075375d35bb1021706217b7407dd
|
4
|
+
data.tar.gz: bccde9071e2872f28e8ce9aed587d469be0d0bee
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 36acab1413f100d033978b02f6b5535c7ac545b20c656725f0712fdcf01b8f8d52e109d88f1b5400a17e282a4fa2d2c2869c2b97d3415693529742109f52a8dd
|
7
|
+
data.tar.gz: de9dd49c4c9aa5c7c12cdcbef430a9f7474b1061663501528f432481f3a10826457711c2a14567e1386afe489a9400179fe471902878e94dcf6d1c9918191049
|
data/config.yaml
CHANGED
Binary file
|
Binary file
|
@@ -9,7 +9,7 @@
|
|
9
9
|
: date
|
10
10
|
2015-12-12
|
11
11
|
: allotted-time
|
12
|
-
|
12
|
+
30m
|
13
13
|
: theme
|
14
14
|
.
|
15
15
|
|
@@ -193,7 +193,7 @@ Not Ruby-ish\n
|
|
193
193
|
|
194
194
|
= Ruby 1.6 times: 2\n(('note:Ruby 1.6の時代:2'))
|
195
195
|
|
196
|
-
*
|
196
|
+
* Started trying to bundle a testing framework to Ruby\n
|
197
197
|
(('note:テスティングフレームワークをRubyにバンドルする'))\n
|
198
198
|
(('note:試みを開始'))
|
199
199
|
* RubyUnit + Lapidary = Test::Unit
|
@@ -236,15 +236,15 @@ Ruby-ish\n
|
|
236
236
|
= Wrap up: Before Ruby 1.8\n(('note:Ruby 1.8の前までのまとめ'))
|
237
237
|
|
238
238
|
* testsupp: Perl like API
|
239
|
-
* RubyUnit:
|
240
|
-
* Lapidary: Not
|
239
|
+
* RubyUnit: Ruby-ish xUnit
|
240
|
+
* Lapidary: Not Ruby-ish xUnit
|
241
241
|
* Test::Unit:
|
242
242
|
* RubyUnit API + Lapidary Impl.
|
243
243
|
|
244
244
|
= Ruby 1.8 times: 1\n(('note:Ruby 1.8の時代:1'))
|
245
245
|
|
246
246
|
* 2003-2013
|
247
|
-
* Ruby
|
247
|
+
* Ruby bundled a testing framework\n
|
248
248
|
(('note:Rubyがテスティングフレームワークをバンドルした'))
|
249
249
|
* Test::Unit aka test/unit\n
|
250
250
|
(('note:バンドルされたのはTest::Unit'))\n
|
@@ -331,7 +331,7 @@ Engl-ish\n
|
|
331
331
|
|
332
332
|
= Wrap up: Ruby 1.8 times\n(('note:Ruby 1.8時代のまとめ'))
|
333
333
|
|
334
|
-
* Ruby
|
334
|
+
* Ruby started bundling Test::Unit (('note:((({/\\Atest.+unit\\z/i})))'))\n
|
335
335
|
(('note:RubyがTest::Unitのバンドルを始めた'))
|
336
336
|
* But Test::Unit was died...\n
|
337
337
|
(('note:バンドル後、Test::Unitは死んだ。。。'))
|
@@ -421,7 +421,7 @@ Engl-ish\n
|
|
421
421
|
= Ruby 2.1 times: 1\n(('note:Ruby 2.1の時代:1'))
|
422
422
|
|
423
423
|
* 2013-
|
424
|
-
* minitest 5 introduced incompatible
|
424
|
+
* minitest 5 introduced incompatible changes\n
|
425
425
|
(('note:minitest 5で非互換の変更が入った'))
|
426
426
|
|
427
427
|
= minitest 5
|
@@ -435,7 +435,7 @@ Engl-ish\n
|
|
435
435
|
|
436
436
|
= Is no test/unit problem?\n(('note:test/unitがないことは問題なのか?'))
|
437
437
|
|
438
|
-
* Ruby used test/unit for Ruby's
|
438
|
+
* Ruby used test/unit for Ruby's tests\n
|
439
439
|
(('note:RubyはRubyのテストにtest/unitを使っていた'))
|
440
440
|
* No test/unit means existing tests can't be worked\n
|
441
441
|
(('note:test/unitがなくなると既存のテストが動かない'))
|
@@ -469,18 +469,18 @@ Accepted!
|
|
469
469
|
|
470
470
|
= Wrap up: Ruby 2.1 times\n(('note:Ruby 2.1時代のまとめ'))
|
471
471
|
|
472
|
-
* Ruby developers decided maintain minitest 4 and test/unit for Ruby's tests\n
|
472
|
+
* Ruby developers decided to maintain minitest 4 and test/unit for Ruby's tests\n
|
473
473
|
(('note:Ruby開発者はRubyのテスト用にminitest 4とtest/unitをメンテナンスすることを決めた'))
|
474
474
|
|
475
475
|
= Ruby 2.2 times: 1\n(('note:Ruby 2.2の時代:1'))
|
476
476
|
|
477
477
|
* 2014-
|
478
|
-
*
|
478
|
+
* Upgraded bundled minitest to 5\n
|
479
479
|
(('note:バンドルしているminitestを5に更新'))
|
480
|
-
*
|
480
|
+
* Moved minitest 4 and test/unit to test/\n
|
481
481
|
(('note:minitest 4とtest/unitはtest/以下に移動'))
|
482
482
|
|
483
|
-
=
|
483
|
+
= Upgraded minitest to 5\n(('note:minitest 5に更新'))
|
484
484
|
|
485
485
|
# coderay diff
|
486
486
|
- lib/minitest/*.rb
|
@@ -492,12 +492,12 @@ Accepted!
|
|
492
492
|
|
493
493
|
= Ruby 2.2 times: 2\n(('note:Ruby 2.2の時代:2'))
|
494
494
|
|
495
|
-
*
|
495
|
+
* Bundled test-unit gem again for users\n
|
496
496
|
(('note:再びtest-unit gemをバンドル'))
|
497
497
|
* Ruby 1.9 dropped test-unit gem\n
|
498
498
|
(('note:Ruby 1.9はtest-unit gemを捨てた'))
|
499
499
|
|
500
|
-
=
|
500
|
+
= Bundled test-unit again\n(('note:test-unitを再びバンドル'))
|
501
501
|
|
502
502
|
test-unit gem provides:
|
503
503
|
|
@@ -514,13 +514,22 @@ test-unit gem provides:
|
|
514
514
|
(('note:ユーザーにとっては'))
|
515
515
|
* lib/test/unit = test-unit gem
|
516
516
|
|
517
|
+
= FYI: test/lib/test/unit
|
518
|
+
|
519
|
+
* Includes useful features for Ruby's tests\n
|
520
|
+
(('note:Ruby本体のテストに便利な機能が入っている'))
|
521
|
+
* Leak checker for file descriptor, thread, process...\n
|
522
|
+
(('note:リークチェッカー:ファイルディスクリプターやスレッドのリークやゾンビプロセスを検出'))
|
523
|
+
* Memory usage profiler\n
|
524
|
+
(('note:メモリー使用量のプロファイラー'))
|
525
|
+
|
517
526
|
= Wrap up: Ruby 2.2 times\n(('note:Ruby 2.2時代のまとめ'))
|
518
527
|
|
519
|
-
*
|
528
|
+
* Bundled minitest 5\n
|
520
529
|
(('note:minitest 5をバンドル'))
|
521
|
-
*
|
530
|
+
* Bundled test-unit again\n
|
522
531
|
(('note:再びtest-unitをバンドル'))
|
523
|
-
* Ruby's tests
|
532
|
+
* Ruby's tests used forked mintiest 4 and test/unit\n
|
524
533
|
(('note:Rubyのテストはフォークしたminitest 4とtest/unitを使う'))
|
525
534
|
|
526
535
|
= Ruby 2.3 times\n(('note:Ruby 2.3の時代'))
|
@@ -528,6 +537,8 @@ test-unit gem provides:
|
|
528
537
|
* 2015-
|
529
538
|
* No highly important things\n
|
530
539
|
(('note:特筆すべきことはない'))
|
540
|
+
* test-unit, minitest, test/lib/test/unit and RSpec were actively developed\n
|
541
|
+
(('note:test-unitもminitestもtest/lib/test/unitもRSpecも活発に開発が進んでいた'))
|
531
542
|
|
532
543
|
= Wrap up: History: 1\n(('note:歴史のまとめ:1'))
|
533
544
|
|
@@ -567,7 +578,7 @@ test-unit gem provides:
|
|
567
578
|
(('note:Ruby 2.1はminitestを5に更新しなかった'))
|
568
579
|
* minitest 5 has backward incompatible changes\n
|
569
580
|
(('note:minitest 5には後方非互換の変更があった'))
|
570
|
-
*
|
581
|
+
* They breaks Ruby's tests\n
|
571
582
|
(('note:非互換を受け入れるとRubyのテストが動かなくなる'))
|
572
583
|
|
573
584
|
= Wrap up: History: 6\n(('note:歴史のまとめ:6'))
|
@@ -587,6 +598,12 @@ test-unit gem provides:
|
|
587
598
|
|
588
599
|
= Wrap up: History: 8\n(('note:歴史のまとめ:8'))
|
589
600
|
|
601
|
+
* test/lib/test/unit was evolved for Ruby's tests\n
|
602
|
+
(('note:test/lib/test/unitはRubyのテスト用に進化した'))
|
603
|
+
* (({/\Atest.+unit\z/i})) in 2.2 too
|
604
|
+
|
605
|
+
= Wrap up: History: 9\n(('note:歴史のまとめ:9'))
|
606
|
+
|
590
607
|
* No highly important things in Ruby 2.3\n
|
591
608
|
(('note:Ruby 2.3には特筆すべきことはない'))
|
592
609
|
|
@@ -613,7 +630,7 @@ Ruby-ish\n
|
|
613
630
|
|
614
631
|
* Write test as normal Ruby script\n
|
615
632
|
(('note:普通のRubyスクリプトのようにテストを書ける'))
|
616
|
-
* It's
|
633
|
+
* It's important in minitest too\n
|
617
634
|
(('note:minitestもこれを大事にしている'))
|
618
635
|
|
619
636
|
= By example: 1\n(('note:実例:1'))
|
@@ -694,9 +711,24 @@ class
|
|
694
711
|
(('note:Test::Unitとminitestはサブクラスでサブテストケースを作ることをサポートしていない'))
|
695
712
|
* test-unit only supports it\n
|
696
713
|
(('note:test-unitだけがサポートしている'))
|
697
|
-
* It's only one incompatible\n
|
714
|
+
* It's the only one incompatible\n
|
698
715
|
(('note:唯一の非互換'))
|
699
716
|
|
717
|
+
= FYI: Group DSL\n(('note:参考情報:グループ化DSL'))
|
718
|
+
|
719
|
+
# coderay ruby
|
720
|
+
class TestCalc < Test::Unit::TestCase
|
721
|
+
sub_test_case "+" do
|
722
|
+
test "positive + negative" {}
|
723
|
+
end
|
724
|
+
sub_test_case "-" do
|
725
|
+
test "positive - negative" {}
|
726
|
+
end
|
727
|
+
end
|
728
|
+
|
729
|
+
(('tag:center'))
|
730
|
+
test-unit feature
|
731
|
+
|
700
732
|
= By example: 2\n(('note:実例:2'))
|
701
733
|
|
702
734
|
(('tag:center'))
|
@@ -730,7 +762,6 @@ module
|
|
730
762
|
class TestKVSOpenStruct < Test::Unit::TestCase
|
731
763
|
include KVSTests
|
732
764
|
def setup; @kvs = OpenStruct.new; end
|
733
|
-
end
|
734
765
|
end
|
735
766
|
|
736
767
|
= Wrap up: Share\n(('note:共有のまとめ'))
|
@@ -814,14 +845,13 @@ Colorized and snippet
|
|
814
845
|
|
815
846
|
# coderay ruby
|
816
847
|
def test_exist_readme
|
817
|
-
assert do
|
848
|
+
assert do # ↓ as-is
|
818
849
|
File.exist?("README")
|
819
|
-
# ↑ as-is
|
820
850
|
end
|
821
851
|
end
|
822
852
|
|
823
853
|
(('tag:center'))
|
824
|
-
|
854
|
+
Built-in in test-unit
|
825
855
|
|
826
856
|
= Message: power-assert
|
827
857
|
|
@@ -869,10 +899,20 @@ Colorized and snippet
|
|
869
899
|
* Clarify differences visually\n
|
870
900
|
(('note:視覚的に違いを明確にする'))
|
871
901
|
|
872
|
-
=
|
902
|
+
= Experiment: 1\n(('note:実験:1'))
|
903
|
+
|
904
|
+
(('tag:center'))
|
905
|
+
Find a difference!\n
|
906
|
+
(('note:違うところを探せ!'))
|
907
|
+
|
908
|
+
Hello | Heilo
|
909
|
+
|
910
|
+
= Experiment: 2\n(('note:実験:2'))
|
911
|
+
|
912
|
+
(('tag:center'))
|
913
|
+
Find a difference!\n
|
914
|
+
(('note:違うところを探せ!'))
|
873
915
|
|
874
|
-
Hello Heilo
|
875
|
-
-----------
|
876
916
|
Hello
|
877
917
|
Heilo
|
878
918
|
|
@@ -889,13 +929,96 @@ Colorized and snippet
|
|
889
929
|
(('tag:center'))
|
890
930
|
(('note:引数だと自然だけどオペランドだと不自然'))
|
891
931
|
|
932
|
+
= FYI: test-unit and power-assert
|
933
|
+
|
934
|
+
* Don't recommend\n
|
935
|
+
"all power-assert"\n
|
936
|
+
(('note:すべてpower-assertは非推奨'))
|
937
|
+
* Recommend "power-assert only for predicate"\n
|
938
|
+
(('note:述語だけpower-assertを推奨'))
|
939
|
+
|
940
|
+
= FYI: Fixture\n(('note:参考情報:フィクスチャー'))
|
941
|
+
|
942
|
+
Ensure\n
|
943
|
+
clean test environment\n
|
944
|
+
(('note:キレイなテスト環境を用意する仕組み'))
|
945
|
+
|
946
|
+
= Fixture: e.g.\n(('note:フィクスチャー:例'))
|
947
|
+
|
948
|
+
# coderay ruby
|
949
|
+
def setup; p :s; end
|
950
|
+
def teardown; p :t; end
|
951
|
+
def test_1; p :t1; end
|
952
|
+
def test_2; p :t2; end
|
953
|
+
# :s -> :t1 -> :t ->
|
954
|
+
# :s -> :t2 -> :t
|
955
|
+
|
956
|
+
= Fixture: Open file\n(('note:フィクスチャー:ファイルを開く'))
|
957
|
+
|
958
|
+
# coderay ruby
|
959
|
+
def setup
|
960
|
+
@file = File.open("x")
|
961
|
+
end
|
962
|
+
def teardown
|
963
|
+
@file.close
|
964
|
+
end
|
965
|
+
|
966
|
+
= Fixture: Open file\n(('note:フィクスチャー:ファイルを開く'))
|
967
|
+
|
968
|
+
Not Ruby-ish\n
|
969
|
+
(('note:Rubyっぽくない'))
|
970
|
+
|
971
|
+
= Fixture: Open File\n(('note:フィクスチャー:ファイルを開く'))
|
972
|
+
|
973
|
+
# coderay ruby
|
974
|
+
def setup # Ruby-ish version
|
975
|
+
File.open("x") do |file|
|
976
|
+
@file = file
|
977
|
+
yield
|
978
|
+
end # Close file automatically
|
979
|
+
end
|
980
|
+
|
981
|
+
(('tag:center'))
|
982
|
+
New feature in test-unit
|
983
|
+
|
892
984
|
= Wrap up: Test::Unit API\n(('note:まとめ:Test::Unit API'))
|
893
985
|
|
894
986
|
* Ruby-ish is important in Test::Unit API\n
|
895
987
|
(('note:Test::Unit APIではRubyらしいことは重要'))
|
896
|
-
|
897
|
-
|
898
|
-
|
899
|
-
|
900
|
-
|
901
|
-
|
988
|
+
|
989
|
+
= Wrap up: Test::Unit API\n(('note:まとめ:Test::Unit API'))
|
990
|
+
|
991
|
+
* (('note:(Sub)')) test case by (('note:(sub)')) class\n
|
992
|
+
(('note:(サブ)テストケースには(サブ)クラスを使う'))
|
993
|
+
* Share tests by module\n
|
994
|
+
(('note:テストの共有にはモジュールを使う'))
|
995
|
+
* as-is in assert\n
|
996
|
+
(('note:アサートではそのままの使い方で書く'))
|
997
|
+
|
998
|
+
= Wrap up: Test::Unit API\n(('note:まとめ:Test::Unit API'))
|
999
|
+
|
1000
|
+
* More Ruby-ish\n
|
1001
|
+
(('note:さらにRubyっぽく'))
|
1002
|
+
* Support block based fixture\n
|
1003
|
+
(('note:ブロックを使ったフィクスチャーもサポート'))
|
1004
|
+
|
1005
|
+
= Goal\n(('note:目標'))
|
1006
|
+
|
1007
|
+
(('tag:center'))
|
1008
|
+
(('tag:large'))
|
1009
|
+
You know about\n
|
1010
|
+
(({/\Atest.+unit\z/i}))
|
1011
|
+
|
1012
|
+
(('tag:center'))
|
1013
|
+
(('note:(({/\\Atest.+unit\\z/i}))を知ること'))
|
1014
|
+
|
1015
|
+
# = Announce\n(('note:おしらせ'))
|
1016
|
+
|
1017
|
+
# # image
|
1018
|
+
# # src = private/images/readable-code-workshop.png
|
1019
|
+
# # relative_height = 100
|
1020
|
+
|
1021
|
+
# == slide property
|
1022
|
+
|
1023
|
+
# : enable-title-on-image
|
1024
|
+
# false
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rabbit-slide-kou-rubykaigi-2015
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2015.12.12.
|
4
|
+
version: 2015.12.12.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Kouhei Sutou
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-12-
|
11
|
+
date: 2015-12-11 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rabbit
|
@@ -56,6 +56,7 @@ files:
|
|
56
56
|
- config.yaml
|
57
57
|
- images/clear-code-is-a-silver-sponsor.png
|
58
58
|
- pdf/rubykaigi-2015-the-history-of-testing-framework-in-ruby.pdf
|
59
|
+
- private/images/readable-code-workshop.png
|
59
60
|
- the-history-of-testing-framework-in-ruby.rab
|
60
61
|
- theme.rb
|
61
62
|
homepage: http://slide.rabbit-shocker.org/authors/kou/rubykaigi-2015/
|