{"id":1926,"date":"2017-02-15T19:43:30","date_gmt":"2017-02-15T11:43:30","guid":{"rendered":"https:\/\/ai.zhousir.top\/?p=1926"},"modified":"2026-08-18T12:09:37","modified_gmt":"2026-08-18T04:09:37","slug":"java%e5%b7%a5%e7%a8%8b%e5%b8%88%e9%9d%a2%e8%af%95%e5%b7%a5%e5%85%b7%e7%af%87%e5%9b%9b","status":"publish","type":"post","link":"https:\/\/ai.zhousir.top\/?p=1926","title":{"rendered":"Java\u5de5\u7a0b\u5e08\u9762\u8bd5\u5de5\u5177\u7bc7(\u56db)"},"content":{"rendered":"<section id=\"wenyan\" style=\"font-family: system-ui, 'Apple Color Emoji', 'Segoe UI', 'Segoe UI Symbol', 'Noto Sans', Roboto, sans-serif; line-height: 1.75; font-size: 16px; color: #000000; caret-color: #000000;\" data-provider=\"WenYan\">\n<p style=\"margin: 1em 0px;\">Java \u5de5\u7a0b\u5e08\u9762\u8bd5\u91cc\uff0c\u5de5\u5177\u94fe\u5e38\u4f1a\u88ab\u95ee\u5230\uff1a<strong style=\"color: #4870ac;\">JUnit<\/strong> \u5355\u5143\u6d4b\u8bd5\u3001<strong style=\"color: #4870ac;\">SVN<\/strong> \u7248\u672c\u7ba1\u7406\u3001<strong style=\"color: #4870ac;\">Maven<\/strong> \u9879\u76ee\u7ba1\u7406\uff0c\u4ee5\u53ca\u65e5\u5fd7\u7ba1\u7406 <strong style=\"color: #4870ac;\">Log4j<\/strong>\u3002\u4e0b\u9762\u6309\u539f\u6587\u8981\u70b9\u6574\u7406\u3002<\/p>\n<h2 style=\"padding: 1px 12.5px; color: #ffffff; margin: 1.2em 0px 1em; border-radius: 4px; display: inline-block; background-color: #4870ac; font-size: 1.3em;\">\u4e00\u3001JUnit \u5355\u5143\u6d4b\u8bd5<\/h2>\n<p style=\"margin: 1em 0px;\">JUnit \u662f\u4e00\u5957\u57fa\u4e8e\u6d4b\u8bd5\u9a71\u52a8\u5f00\u53d1\u7684\u6d4b\u8bd5\u6846\u67b6\u3002<\/p>\n<blockquote style=\"display: block; font-size: 0.9em; border-left: 3px solid #4870ac; padding: 0.5em 1em; margin: 0px; background: #f6f8fa; color: #40464f;\">\n<p style=\"margin: 1em 0px;\">\u6ce8\uff1aJUnit4 \u4e0d\u9700\u8981\u7ee7\u627f <code style=\"font-family: Menlo, Monaco, Consolas, 'Liberation Mono', 'Roboto Mono', 'Courier New', 'Microsoft YaHei', monospace; color: #4870ac; font-size: 0.9em; font-weight: normal; overflow-wrap: break-word; padding: 2px 4px; border-radius: 3px; margin: 2px; background-color: #f6f8fa; word-break: break-all;\">junit.framework.TestCase<\/code> \u7c7b\u3002<\/p>\n<p style=\"margin: 1em 0px;\">JUnit3 \u4e2d\u6240\u6709\u7684\u65b9\u6cd5\u90fd\u5fc5\u987b\u4f7f\u7528 <code style=\"font-family: Menlo, Monaco, Consolas, 'Liberation Mono', 'Roboto Mono', 'Courier New', 'Microsoft YaHei', monospace; color: #4870ac; font-size: 0.9em; font-weight: normal; overflow-wrap: break-word; padding: 2px 4px; border-radius: 3px; margin: 2px; background-color: #f6f8fa; word-break: break-all;\">@Test<\/code> \u6ce8\u89e3\uff0c\u5e76\u4e14\u9700\u8981\u5728\u65b9\u6cd5\u540d\u524d\u52a0 test \u4f5c\u4e3a\u524d\u7f00\uff0c\u9700\u8981\u7ee7\u627f <code style=\"font-family: Menlo, Monaco, Consolas, 'Liberation Mono', 'Roboto Mono', 'Courier New', 'Microsoft YaHei', monospace; color: #4870ac; font-size: 0.9em; font-weight: normal; overflow-wrap: break-word; padding: 2px 4px; border-radius: 3px; margin: 2px; background-color: #f6f8fa; word-break: break-all;\">junit.framework.TestCase<\/code> \u7c7b\u3002<\/p>\n<\/blockquote>\n<h2 style=\"padding: 1px 12.5px; color: #ffffff; margin: 1.2em 0px 1em; border-radius: 4px; display: inline-block; background-color: #4870ac; font-size: 1.3em;\">\u4e8c\u3001\u7248\u672c\u7ba1\u7406\u5de5\u5177 SVN<\/h2>\n<p style=\"margin: 1em 0px;\">SVN \u662f\u4e00\u4e2a\u5f00\u653e\u6e90\u4ee3\u7801\u7684\u7248\u672c\u63a7\u5236\u7cfb\u7edf\u3002<\/p>\n<blockquote style=\"display: block; font-size: 0.9em; border-left: 3px solid #4870ac; padding: 0.5em 1em; margin: 0px; background: #f6f8fa; color: #40464f;\">\n<p style=\"margin: 1em 0px;\">\u4e3e\u4e2a\u4f8b\u5b50\uff1a<\/p>\n<ul style=\"padding-left: 1rem; margin-left: 1rem; font-size: 0.9rem; list-style-type: disc;\">\n<li>\n<section>\u2460 \u4e2a\u4eba\u7684\u4ee3\u7801 \u2192 \u53e3\u888b\u91cc\u7684\u94b1<\/section>\n<\/li>\n<li>\n<section>\u2461 \u7248\u672c\u63a7\u5236\u5de5\u5177\u4e2d\u7684\u4ee3\u7801 \u2192 \u5361\u91cc\u7684\u94b1<\/section>\n<\/li>\n<li>\n<section>\u2462 \u7248\u672c\u63a7\u5236\u5de5\u5177\u4e2d\u7684\u5ba2\u6237\u7aef \u2192 \u5361<\/section>\n<\/li>\n<li>\n<section>\u2463 \u7248\u672c\u63a7\u5236\u5de5\u5177\u4e2d\u7684\u670d\u52a1\u7aef \u2192 \u5237\u5361\u673a<\/section>\n<\/li>\n<\/ul>\n<p style=\"margin: 1em 0px;\">\u6ce8\uff1a\u5728\u5b9e\u9645\u7248\u672c\u7ba1\u7406\u5f53\u4e2d\uff0c\u4f60\u6240\u5199\u7684\u4ee3\u7801\uff0c\u9700\u8981\u63d0\u4ea4\u7ed9\u670d\u52a1\u7aef\uff0c\u7136\u540e\u522b\u4eba\u8981\u4fee\u6539\u4f60\u7684\u4ee3\u7801\uff0c\u5c31\u4f1a\u4ece\u670d\u52a1\u7aef\u66f4\u65b0\u5f53\u524d\u76ee\u5f55\u4e0b\u7684\u4ee3\u7801\uff0c\u518d\u8fdb\u884c\u4fee\u6539\u548c\u63d0\u4ea4\u3002\u6240\u4ee5\uff0c\u201c\u5361\u91cc\u7684\u94b1\u201d\u53ef\u4ee5\u7406\u89e3\u4e3a\u56e2\u961f\u516c\u6709\u7684\u4ee3\u7801\u4f53\u7cfb\u3002<\/p>\n<\/blockquote>\n<h2 style=\"padding: 1px 12.5px; color: #ffffff; margin: 1.2em 0px 1em; border-radius: 4px; display: inline-block; background-color: #4870ac; font-size: 1.3em;\">\u4e09\u3001\u9879\u76ee\u7ba1\u7406\u5de5\u5177 Maven<\/h2>\n<p style=\"margin: 1em 0px;\">Maven \u662f\u57fa\u4e8e\u9879\u76ee\u5bf9\u8c61\u6a21\u578b\uff08POM\uff09\uff0c\u53ef\u4ee5\u901a\u8fc7\u4e00\u5c0f\u6bb5\u63cf\u8ff0\u4fe1\u606f\u6765\u7ba1\u7406\u9879\u76ee\u7684\u6784\u5efa\u3001\u62a5\u544a\u548c\u6587\u6863\u7684\u8f6f\u4ef6\u9879\u76ee\u7ba1\u7406\u5de5\u5177\u3002<\/p>\n<blockquote style=\"display: block; font-size: 0.9em; border-left: 3px solid #4870ac; padding: 0.5em 1em; margin: 0px; background: #f6f8fa; color: #40464f;\">\n<p style=\"margin: 1em 0px;\">\u6ce8\uff1aMaven \u4e5f\u662f\u4e00\u5957\u5f3a\u5927\u7684\u81ea\u52a8\u5316\u7684\u7ba1\u7406\u5de5\u5177\uff0c\u8986\u76d6\u4e86\u7f16\u8bd1\u3001\u6d4b\u8bd5\u3001\u8fd0\u884c\u3001\u6e05\u7406\u3001\u6253\u5305\u548c\u90e8\u7f72\uff0c\u6574\u4e2a\u9879\u76ee\u6784\u5efa\u7684\u5468\u671f\u3002<\/p>\n<p style=\"margin: 1em 0px;\">\u5b83\u8fd8\u63d0\u4f9b\u4e86\u4e00\u4e2a\u4ed3\u5e93\u7684\u6982\u5ff5\uff0c\u7edf\u4e00\u7684\u5e2e\u52a9\u5f00\u53d1\u4eba\u5458\u7ba1\u7406\u9879\u76ee\u6240\u4f9d\u8d56\u7684\u7b2c\u4e09\u65b9\u7684\u67b6\u5305\uff0c\u6700\u5927\u53ef\u80fd\u7684\u907f\u514d\u73af\u5883\u914d\u7f6e\u4e0d\u540c\u6240\u4ea7\u751f\u7684\u95ee\u9898\uff08\u5728\u4f60\u7684\u7535\u8111\u4e0a\u80fd\u8fd0\u884c\uff0c\u5728\u6211\u7684\u7535\u8111\u4e0a\u5c31\u4e0d\u80fd\u8fd0\u884c\uff09\u3002<\/p>\n<\/blockquote>\n<h2 style=\"padding: 1px 12.5px; color: #ffffff; margin: 1.2em 0px 1em; border-radius: 4px; display: inline-block; background-color: #4870ac; font-size: 1.3em;\">\u56db\u3001\u65e5\u5fd7\u7ba1\u7406 Log4j<\/h2>\n<p style=\"margin: 1em 0px;\">\u65e5\u5fd7\u7ba1\u7406 Log4j\u3002<\/p>\n<table style=\"display: table; text-align: left; overflow: auto; border-collapse: collapse; margin: 1.4em auto; max-width: 100%; table-layout: fixed; overflow-wrap: break-word; word-break: break-all;\" width=\"800\">\n<thead>\n<tr>\n<th style=\"border: 1px solid #d9dfe4; padding: 9px 12px; font-size: 0.75em; line-height: 22px; vertical-align: top; text-align: center; font-weight: bold; color: #4870ac; background: #f7f7f7;\">\u5de5\u5177<\/th>\n<th style=\"border: 1px solid #d9dfe4; padding: 9px 12px; font-size: 0.75em; line-height: 22px; vertical-align: top; text-align: center; font-weight: bold; color: #4870ac; background: #f7f7f7;\">\u4e00\u53e5\u8bdd<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td style=\"border: 1px solid #d9dfe4; padding: 9px 12px; font-size: 0.75em; line-height: 22px; vertical-align: top;\">JUnit<\/td>\n<td style=\"border: 1px solid #d9dfe4; padding: 9px 12px; font-size: 0.75em; line-height: 22px; vertical-align: top;\">\u57fa\u4e8e\u6d4b\u8bd5\u9a71\u52a8\u5f00\u53d1\u7684\u6d4b\u8bd5\u6846\u67b6<\/td>\n<\/tr>\n<tr>\n<td style=\"border: 1px solid #d9dfe4; padding: 9px 12px; font-size: 0.75em; line-height: 22px; vertical-align: top;\">SVN<\/td>\n<td style=\"border: 1px solid #d9dfe4; padding: 9px 12px; font-size: 0.75em; line-height: 22px; vertical-align: top;\">\u5f00\u653e\u6e90\u4ee3\u7801\u7684\u7248\u672c\u63a7\u5236\u7cfb\u7edf<\/td>\n<\/tr>\n<tr>\n<td style=\"border: 1px solid #d9dfe4; padding: 9px 12px; font-size: 0.75em; line-height: 22px; vertical-align: top;\">Maven<\/td>\n<td style=\"border: 1px solid #d9dfe4; padding: 9px 12px; font-size: 0.75em; line-height: 22px; vertical-align: top;\">\u57fa\u4e8e POM \u7ba1\u7406\u6784\u5efa\u3001\u62a5\u544a\u548c\u6587\u6863<\/td>\n<\/tr>\n<tr>\n<td style=\"border: 1px solid #d9dfe4; padding: 9px 12px; font-size: 0.75em; line-height: 22px; vertical-align: top;\">Log4j<\/td>\n<td style=\"border: 1px solid #d9dfe4; padding: 9px 12px; font-size: 0.75em; line-height: 22px; vertical-align: top;\">\u65e5\u5fd7\u7ba1\u7406<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<blockquote style=\"display: block; font-size: 0.9em; border-left: 3px solid #4870ac; padding: 0.5em 1em; margin: 0px; background: #f6f8fa; color: #40464f;\">\n<p style=\"margin: 1em 0px;\"><strong style=\"color: #4870ac;\">\u4e00\u53e5\u8bdd\u603b\u7ed3\uff1a\u9762\u8bd5\u5de5\u5177\u7bc7\u628a\u6d4b\u8bd5\uff08JUnit\uff09\u3001\u7248\u672c\uff08SVN\uff09\u3001\u6784\u5efa\uff08Maven\uff09\u548c\u65e5\u5fd7\uff08Log4j\uff09\u4e32\u6210\u4e00\u5957\u65e5\u5e38\u5f00\u53d1\u5de5\u5177\u94fe\u3002<\/strong><\/p>\n<\/blockquote>\n<\/section>\n","protected":false},"excerpt":{"rendered":"<p>Java \u5de5\u7a0b\u5e08\u9762\u8bd5\u91cc\uff0c\u5de5\u5177\u94fe\u5e38\u4f1a\u88ab\u95ee\u5230\uff1aJUnit \u5355\u5143\u6d4b\u8bd5\u3001SVN \u7248\u672c\u7ba1\u7406\u3001Maven \u9879\u76ee\u7ba1\u7406\uff0c\u4ee5\u53ca\u65e5 [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[46],"tags":[43,171,140],"_links":{"self":[{"href":"https:\/\/ai.zhousir.top\/index.php?rest_route=\/wp\/v2\/posts\/1926"}],"collection":[{"href":"https:\/\/ai.zhousir.top\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/ai.zhousir.top\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/ai.zhousir.top\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/ai.zhousir.top\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=1926"}],"version-history":[{"count":1,"href":"https:\/\/ai.zhousir.top\/index.php?rest_route=\/wp\/v2\/posts\/1926\/revisions"}],"predecessor-version":[{"id":1927,"href":"https:\/\/ai.zhousir.top\/index.php?rest_route=\/wp\/v2\/posts\/1926\/revisions\/1927"}],"wp:attachment":[{"href":"https:\/\/ai.zhousir.top\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=1926"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/ai.zhousir.top\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=1926"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/ai.zhousir.top\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=1926"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}