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
Refactoring Re-education
Search
Terry
February 25, 2013
Programming
5
960
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
710
RubyConf China Welcome Slides
poshboytl
1
78
Rails Girls Chengdu 2014
poshboytl
2
320
How we test our projects
poshboytl
29
1.9k
Other Decks in Programming
See All in Programming
理論と実務のギャップを超える
eycjur
0
180
テーブル定義書の構造化抽出して、生成AIでDWH分析を試してみた / devio2025tokyo
kasacchiful
0
280
Devvox Belgium - Agentic AI Patterns
kdubois
1
140
Domain-centric? Why Hexagonal, Onion, and Clean Architecture Are Answers to the Wrong Question
olivergierke
3
960
AI 駆動開発におけるコミュニティと AWS CDK の価値
konokenj
5
220
The Past, Present, and Future of Enterprise Java
ivargrimstad
0
450
Devoxx BE - Local Development in the AI Era
kdubois
0
140
スマホから Youtube Shortsを見られないようにする
lemolatoon
27
34k
The Past, Present, and Future of Enterprise Java
ivargrimstad
0
610
Goで実践するドメイン駆動開発 AIと歩み始めた新規プロダクト開発の現在地
imkaoru
4
890
Introduce Hono CLI
yusukebe
6
3.1k
Things You Thought You Didn’t Need To Care About That Have a Big Impact On Your Job
hollycummins
0
250
Featured
See All Featured
The Cult of Friendly URLs
andyhume
79
6.6k
Sharpening the Axe: The Primacy of Toolmaking
bcantrill
46
2.5k
The Invisible Side of Design
smashingmag
302
51k
Product Roadmaps are Hard
iamctodd
PRO
55
11k
The Cost Of JavaScript in 2023
addyosmani
55
9.1k
The Success of Rails: Ensuring Growth for the Next 100 Years
eileencodes
46
7.7k
Music & Morning Musume
bryan
46
6.9k
Building an army of robots
kneath
305
46k
Chrome DevTools: State of the Union 2024 - Debugging React & Beyond
addyosmani
9
930
RailsConf & Balkan Ruby 2019: The Past, Present, and Future of Rails at GitHub
eileencodes
140
34k
Fireside Chat
paigeccino
41
3.7k
StorybookのUI Testing Handbookを読んだ
zakiyama
31
6.2k
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!!