Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
RaaP
Search
ksss
May 08, 2024
Programming
0
280
RaaP
ksss
May 08, 2024
Tweet
Share
More Decks by ksss
See All by ksss
Railsの型ファイル自動生成における課題と解決
ksss
4
3.9k
RBS generation framework using Rack architecture
ksss
0
6.5k
mrubyでruby/specを走らせてみた結果www
ksss
1
2.4k
Rubyに型があると便利か
ksss
4
4.4k
A New Testing Framework Rgot
ksss
0
1.2k
mruby hacking guide
ksss
7
1.8k
Other Decks in Programming
See All in Programming
Ruby メモリ管理 プログラミング
megmogmog1965
0
130
Folding Cheat Sheet #7
philipschwarz
PRO
0
150
Product Management LT会_クアンド新家
shinshin
0
210
CSC307 Lecture 05
javiergs
PRO
0
210
CSC307 Lecture 14
javiergs
PRO
0
220
3 Effective Rules for Success with Signals in Angular
manfredsteyer
PRO
0
120
AWS初心者ってどうやってAWSを学ぶ?〜アプリエンジニアがやってよかったアーキテクチャ学習方法〜
yamanashi_ren01
0
190
Javaの現状2024夏 / Java current status 2024 summer
kishida
4
1.4k
最古の関数型言語「Lisp」ことはじめ / lisp_in_kamiyama
uhooi
1
190
ぼっちを避けて楽しむためのアノテコノテ / Various Tips and Tricks to Avoid Loneliness and Have Fun
nrslib
3
1.7k
みんなのオブザーバビリティプラットフォームを作ってるんだがパフォーマンスがやばい #mackerelio #srenext
ne_sachirou
0
370
CSC307 Lecture 09
javiergs
PRO
1
500
Featured
See All Featured
Embracing the Ebb and Flow
colly
81
4.3k
Fight the Zombie Pattern Library - RWD Summit 2016
marcelosomers
228
16k
Speed Design
sergeychernyshev
9
270
[RailsConf 2023] Rails as a piece of cake
palkan
35
4.4k
Why Our Code Smells
bkeepers
PRO
332
56k
What the flash - Photography Introduction
edds
65
11k
What’s in a name? Adding method to the madness
productmarketing
PRO
21
2.9k
How GitHub Uses GitHub to Build GitHub
holman
471
290k
10 Git Anti Patterns You Should be Aware of
lemiorhan
652
58k
Easily Structure & Communicate Ideas using Wireframe
afnizarnur
189
16k
Designing the Hi-DPI Web
ddemaree
276
34k
Creating an realtime collaboration tool: Agile Flush - .NET Oxford
marcduiker
16
1.6k
Transcript
ksss Run your RBS like a testing code. RBS as
a Property
RBS as a Property ✒ RBS class MyClass def my_method:
(Integer, Integer) -> Integer end
RBS as a Property 🍎 Property 100.times do int1 =
Random.rand(100) int2 = Random.rand(100) result = MyClass.new.my_method(int1, int2) assert_kind_of Integer, result end
RBS as a Property ✒🍎
RBS as a Property Gener a te test c a
se by RBS And execute code a utom a tic a lly
https://github.com/ksss/raap This is the RaaP
Demo
Edit RBS (Add one overload) class MyClass def my_method: (Integer,
Integer) -> Integer | (Float, Float) -> Float end
You can run RBS instantly!
If the RBS is wrong? class MyClass def my_method: (Integer,
String) -> Integer end
It detects failures and also displays reproduction codes.
Support Union type class MyClass def my_method: (0 | 1
| 2, 3 | 4 | 5) -> Integer end
Choose one of the Unions and run it. With coverage!
RBS as a Property RaaP