{"action":"created","issue":{"url":"https://api.github.com/repos/tw-oocamp-201512/questions/issues/20","labels_url":"https://api.github.com/repos/tw-oocamp-201512/questions/issues/20/labels{/name}","comments_url":"https://api.github.com/repos/tw-oocamp-201512/questions/issues/20/comments","events_url":"https://api.github.com/repos/tw-oocamp-201512/questions/issues/20/events","html_url":"https://github.com/tw-oocamp-201512/questions/issues/20","id":120148883,"number":20,"title":"是否需要对Domain Model的设计使用TDD?","user":{"login":"sunjintw","id":15727276,"avatar_url":"https://avatars.githubusercontent.com/u/15727276?v=3","gravatar_id":"","url":"https://api.github.com/users/sunjintw","html_url":"https://github.com/sunjintw","followers_url":"https://api.github.com/users/sunjintw/followers","following_url":"https://api.github.com/users/sunjintw/following{/other_user}","gists_url":"https://api.github.com/users/sunjintw/gists{/gist_id}","starred_url":"https://api.github.com/users/sunjintw/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sunjintw/subscriptions","organizations_url":"https://api.github.com/users/sunjintw/orgs","repos_url":"https://api.github.com/users/sunjintw/repos","events_url":"https://api.github.com/users/sunjintw/events{/privacy}","received_events_url":"https://api.github.com/users/sunjintw/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-12-03T11:22:20Z","updated_at":"2015-12-04T01:32:51Z","closed_at":null,"body":""},"comment":{"url":"https://api.github.com/repos/tw-oocamp-201512/questions/issues/comments/161846017","html_url":"https://github.com/tw-oocamp-201512/questions/issues/20#issuecomment-161846017","issue_url":"https://api.github.com/repos/tw-oocamp-201512/questions/issues/20","id":161846017,"user":{"login":"wj1s","id":886774,"avatar_url":"https://avatars.githubusercontent.com/u/886774?v=3","gravatar_id":"","url":"https://api.github.com/users/wj1s","html_url":"https://github.com/wj1s","followers_url":"https://api.github.com/users/wj1s/followers","following_url":"https://api.github.com/users/wj1s/following{/other_user}","gists_url":"https://api.github.com/users/wj1s/gists{/gist_id}","starred_url":"https://api.github.com/users/wj1s/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/wj1s/subscriptions","organizations_url":"https://api.github.com/users/wj1s/orgs","repos_url":"https://api.github.com/users/wj1s/repos","events_url":"https://api.github.com/users/wj1s/events{/privacy}","received_events_url":"https://api.github.com/users/wj1s/received_events","type":"User","site_admin":false},"created_at":"2015-12-04T01:32:50Z","updated_at":"2015-12-04T01:32:50Z","body":"是可以的，但是可以结合DDD。因为系统或是产品最终是满足业务需求的，而TDD就是先想清业务，付之于测试，然后再驱动出实现，而DomainModel是实现的一部分，所以自然可以。\r\n\r\n但是DDD，DCI甚至通过Event的方式只是实现方式策略的不同，具体采用哪种实现方式是无法通过TDD驱动的（例如有个API，发一个请求/hello 返回一个{hello}，你可以用很多种方式来实现，测试不能决定你用什么，测试只能保证你实现了需求），所以这些设计的知识同样需要。\r\n\r\nTDD中测试永远关注在业务上而不是实现上"}}