Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
使い捨てAPIテストのすすめ
Search
izumix03
February 09, 2024
Business
260
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
使い捨てAPIテストのすすめ
izumix03
February 09, 2024
Other Decks in Business
See All in Business
エムスリーキャリア Work Support採用資料 / M3C Work Support
m3c
1
15k
株式会社デライト 会社紹介資料
ikmwatanabe
0
440
AI立国論(2026年9月)
noritaka88tax
0
230
アカウント営業_候補者様向け資料
mayu1001
0
240
事業本部紹介資料_261001
mwktp
0
550
インパクトレポート2026
nessu_inc
0
1.7k
AIと働く実践 Agentがあなたの生産性を上げてくれない理由
ozakiomumkj
1
180
AI活用の舞台装置が、自走を促す
tbpgr
0
270
EDRを入れたので 安心しきっていませんか? 「導入した」から、「使いこなす」へ。
kamadamakoto
0
150
クリヤマホールディングス㈱採用資料
uemura2024
0
9.3k
小さく早く作る って 本当に正しいの?— GTMの観点から見るアジャイル開発
ryu1013
0
180
Crisp Code inc.|コーポレート・サービス紹介 - Corporate & Services Introduction
so_kotani
0
620
Featured
See All Featured
<Decoding/> the Language of Devs - We Love SEO 2024
nikkihalliwell
1
360
Crafting Experiences
bethany
1
390
The Invisible Side of Design
smashingmag
301
52k
Design in an AI World
tapps
1
360
CSS Pre-Processors: Stylus, Less & Sass
bermonpainter
360
31k
技術選定の審美眼(2025年版) / Understanding the Spiral of Technologies 2025 edition
twada
PRO
120
120k
Building Experiences: Design Systems, User Experience, and Full Site Editing
marktimemedia
1
640
Odyssey Design
rkendrick25
PRO
2
890
How People are Using Generative and Agentic AI to Supercharge Their Products, Projects, Services and Value Streams Today
helenjbeal
2
370
Mind Mapping
helmedeiros
1
400
Optimising Largest Contentful Paint
csswizardry
37
4k
Fashionably flexible responsive web design (full day workshop)
malarkey
409
67k
Transcript
使い捨てAPIテストのすすめ ~取得系APIのリプレイスで使えるTips~ DeNA SOMPO Mobility 泉川 貴洋
WEB APIのリプレイって⼤変... 2 実際にやってよかったTips 使い捨てAPIテスト どういう仕様?複雑すぎる... テストもない... 既存APIと同じ挙動を保証?!!
3 泉川 貴洋 / いずみかわ たかひろ 所属 DeNA SOMPO Mobility
グロース本部プロダクト開発部 担当 Anyca サーバサイドエンジニア 出⾝ ⾹川県 家族構成 妻と2歳の娘の3⼈家族 @izumix0303
エニカとは 新型⾞‧⾼級⾞など1,300以上の⾞種に乗れる、 個⼈間を中⼼としたカーシェアサービス。 カーシェアを通じた理想のライフスタイルを提供 4
‧データ準備(登録, DB Dump,etc...) ‧リクエストと正解レスポンスを定義 ‧CIなどで継続的に実⾏ 5 使い捨てAPIテスト? ⼀般的なAPIテスト 使い捨てAPIテスト ‧データ準備(登録,
DB Dump,etc...) ‧リクエストだけ定義 ‧開発終わったら破棄 = 使い捨て
使い捨てAPIテストの構築⼿順 ①古いエンドポイント 旧 新 ②新エンドポイントを 別に作る ③テストを書く GET old/hoge/1 レスポンス取得
新旧のレスポンス⽐較! GET new/hoge/1 ④開発 DB
使い捨てAPIテストの作り⽅ ‧Jupyter Labで作る ‧pythonに変換して実⾏ ‧pytest-clarity で差分を⾒やすくする
Jupyter Labで作る 対話的に確認しながら作れる
Pythonに変換 Makefileの例 Pythonに変換しながら Pytestを実⾏ NOTEBOOKS:=$(shell find src/test -name "*.ipynb") PYS:=$(NOTEBOOKS:.ipynb=.py)
.PHONY: convert convert: $(PYS) %.py: %.ipynb $(VENV)/jupyter nbconvert --to python $< .PHONY: test test: convert $(VENV)/pytest -vv ./src/test/**/*.py include Makefile.venv
pytest-clarity で差分を⾒やすくする JSONの差分を、 ⾊付けして ⾒せてくれる
使い捨てAPIテストのメリット 作りやすさ 簡単に 作れる 質 保証内容が 確実 量 パターンも ⼗分確保
Let's 快適なAPIリプレイス!