Skip to content

Instantly share code, notes, and snippets.

@tomoyamkung
Last active October 13, 2015 15:12
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save tomoyamkung/3d5f3b3abcaf98ef13e0 to your computer and use it in GitHub Desktop.
Save tomoyamkung/3d5f3b3abcaf98ef13e0 to your computer and use it in GitHub Desktop.
[Eclipse,JUnit]JUnit のテストメソッド作成テンプレート
<?xml version="1.0" encoding="UTF-8" standalone="no"?><templates><template autoinsert="true" context="java-members" deleted="false" description="" enabled="true" name="test_abnormal">@${testType:newType(org.junit.Test)}
public void 異常系_${testName}() throws Exception {
${staticImport:importStatic('org.junit.Assert.*')}${cursor}// setup
// exercise
// verify
}</template><template autoinsert="true" context="java-members" deleted="false" description="" enabled="true" name="test_normal">@${testType:newType(org.junit.Test)}
public void 正常系_${testName}() throws Exception {
${staticImport:importStatic('org.junit.Assert.*')}${cursor}// setup
// exercise
// verify
}</template><template autoinsert="true" context="java-members" deleted="false" description="" enabled="true" name="test_semi_normal">@${testType:newType(org.junit.Test)}
public void 準正常系_${testName}() throws Exception {
${staticImport:importStatic('org.junit.Assert.*')}${cursor}// setup
// exercise
// verify
}</template></templates>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment