$30 off During Our Annual Pro Sale. View Details »
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Refactoring Re-education
Search
Terry
February 25, 2013
Programming
5
980
Refactoring Re-education
Summarize the work for refactoring Re-education project.
Terry
February 25, 2013
Tweet
Share
More Decks by Terry
See All by Terry
Building API For The REST of Us
poshboytl
8
720
RubyConf China Welcome Slides
poshboytl
1
86
Rails Girls Chengdu 2014
poshboytl
2
320
How we test our projects
poshboytl
29
1.9k
Other Decks in Programming
See All in Programming
0→1 フロントエンド開発 Tips🚀 #レバテックMeetup
bengo4com
0
310
公共交通オープンデータ × モバイルUX 複雑な運行情報を 『直感』に変換する技術
tinykitten
PRO
0
160
從冷知識到漏洞,你不懂的 Web,駭客懂 - Huli @ WebConf Taiwan 2025
aszx87410
2
2.9k
SwiftUIで本格音ゲー実装してみた
hypebeans
0
480
Kotlin Multiplatform Meetup - Compose Multiplatform 외부 의존성 아키텍처 설계부터 운영까지
wisemuji
0
110
Denoのセキュリティに関する仕組みの紹介 (toranoana.deno #23)
uki00a
0
150
組み合わせ爆発にのまれない - 責務分割 x テスト
halhorn
1
160
Socio-Technical Evolution: Growing an Architecture and Its Organization for Fast Flow
cer
PRO
0
390
TestingOsaka6_Ozono
o3
0
170
脳の「省エネモード」をデバッグする ~System 1(直感)と System 2(論理)の切り替え~
panda728
PRO
0
120
Jetpack XR SDKから紐解くAndroid XR開発と技術選定のヒント / about-androidxr-and-jetpack-xr-sdk
drumath2237
1
180
Canon EOS R50 V と R5 Mark II 購入でみえてきた最近のデジイチ VR180 事情、そして VR180 静止画に活路を見出すまで
karad
0
130
Featured
See All Featured
Put a Button on it: Removing Barriers to Going Fast.
kastner
60
4.1k
Getting science done with accelerated Python computing platforms
jacobtomlinson
0
76
Bioeconomy Workshop: Dr. Julius Ecuru, Opportunities for a Bioeconomy in West Africa
akademiya2063
PRO
0
31
Marketing Yourself as an Engineer | Alaka | Gurzu
gurzu
0
89
Discover your Explorer Soul
emna__ayadi
2
1k
The Illustrated Guide to Node.js - THAT Conference 2024
reverentgeek
0
210
Unsuck your backbone
ammeep
671
58k
HDC tutorial
michielstock
0
260
Docker and Python
trallard
47
3.7k
Leadership Guide Workshop - DevTernity 2021
reverentgeek
0
160
AI: The stuff that nobody shows you
jnunemaker
PRO
1
7
Kristin Tynski - Automating Marketing Tasks With AI
techseoconnect
PRO
0
110
Transcript
Refactoring re-education Terry Tai
who am i
太檑
Terry
@poshboytl
Co-founder of Pragmatic.ly
None
Creator of railscasts-china.com
None
What refactoring is
Refactoring is improving the design of codes without changing it’s
behaviour.
How to begin
Run tests
How about if there is no test
Write integration tests to protect the user heavier
Unit tests might be change when doing refactor
I choose Rspec/Capybara
Code Conventions
Use spaces instead of tabs
None
None
Do not use unless ... else...
None
Don’t require things several times
None
Conventions might be different in different teams
Code design
None
None
Put filter method in private/protected
None
None
Slim controllers Fat models
None
None
None
None
None
Refactor in your daily work
Write tests
It’s better if you do TDD
Pair with your friends sometimes
Almost never push codes to master straightly
Create branch for every ticket
Send Pull Request And do code review
Make sure running tests before you push
Treat every piece of your codes as open source codes
About README • Explain why your code exists. • Tell
people how to use it • Declare copyright and licensing • Describe how to conribute
Keep Rocking!!