Skip to Content
훌륭한 프로그래머 되는 법: 프로젝트와 팀을 성공으로 이끄는 선배 개발자의 노하우
book

훌륭한 프로그래머 되는 법: 프로젝트와 팀을 성공으로 이끄는 선배 개발자의 노하우

by 최원재, 강전희, 안재덕, 남윤화, 피트 구들리프
May 2016
Beginner to intermediate
438 pages
8h 46m
Korean
Hanbit Media, Inc.
Content preview from 훌륭한 프로그래머 되는 법: 프로젝트와 팀을 성공으로 이끄는 선배 개발자의 노하우
140
1
부
you.write(code) ;
물론 앞에서 소개한 테스트만으로는 문자열의 대문자로의 변환과 관련된 모든 경우의 수를 커
버할 수 없다. 다른 입력 값과 그에 대한 기대 결과를 다루는 테스트들도 필요하다. 각 테스트
는 새로운 테스트 함수로 만들어져야 하며, 다른 테스트에 통합되어서는 안 된다.
11.7.1
테스트 이름
하나의 기능 검증에 집중하는 테스트에는 명확한 이름이 붙어 있어서 간단한 문장처럼 읽힌다.
만약 테스트 케이스 이름을 간단히 붙일 수 없다면, 요구사항이 모호하거나 혹은 여러 가지를
한꺼번에 테스트하려는 것일 수 있다.
앞에서 본 바과 같이, 테스트 메서드에는 @
Test
와 같은 특성이 지정되므로 메서드 명에
test
라는 단어를 포함시킬 필요는 없다. 다시 말해 예제의 메서드 명을
testThatStringsCan
BeCapitalized
로 지을 필요가 없다.
테스트들이 코드에 대한 명세 사항으로서 읽힌다고 가정하라. 각 테스트의 이름은 테스트 대
상 시스템(
SUT
)을 실행하는 것에 대한 설명, 즉 단 하나의 정의에 대한 설명이다. ‘
should
’나
‘
must
’와 같이 실제 행위에 대한 것이 아닌 단어를 쓰지 말라. 구현 코드를 작성할 때와 마찬가
지로, 불필요하게 긴 이름은 피하라.
테스트의 이름을 굳이 구현 코드와 같은 형식으로 지을 필요는 없다. 각자 서로에게 맞는 영역
의 언어가 있을 수 있다. 보통 더 길면서 서술적인 메서드 명에 밑줄 표시(
underscore
)를 자
유롭게 쓰는 경우를 많이 볼 수 있
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.

Read now

Unlock full access

More than 5,000 organizations count on O’Reilly

AirBnbBlueOriginElectronic ArtsHomeDepotNasdaqRakutenTata Consultancy Services

QuotationMarkO’Reilly covers everything we've got, with content to help us build a world-class technology community, upgrade the capabilities and competencies of our teams, and improve overall team performance as well as their engagement.
Julian F.
Head of Cybersecurity
QuotationMarkI wanted to learn C and C++, but it didn't click for me until I picked up an O'Reilly book. When I went on the O’Reilly platform, I was astonished to find all the books there, plus live events and sandboxes so you could play around with the technology.
Addison B.
Field Engineer
QuotationMarkI’ve been on the O’Reilly platform for more than eight years. I use a couple of learning platforms, but I'm on O'Reilly more than anybody else. When you're there, you start learning. I'm never disappointed.
Amir M.
Data Platform Tech Lead
QuotationMarkI'm always learning. So when I got on to O'Reilly, I was like a kid in a candy store. There are playlists. There are answers. There's on-demand training. It's worth its weight in gold, in terms of what it allows me to do.
Mark W.
Embedded Software Engineer

You might also like

클라우드 네이티브: 클라우드 네이티브 애플리케이션을 설계, 개발, 운영하는 핵심 가이드

클라우드 네이티브: 클라우드 네이티브 애플리케이션을 설계, 개발, 운영하는 핵심 가이드

정원천, 보리스 숄, 트렌트 스완슨, 피터 야우쇼베츠

Publisher Resources

ISBN: 9788968482304