1.安装插件File -> Settings -> Plugins 然后输入Junit 2.重启Idea 3.在你要创建测试用例的类中按 Ctrl + Shift + T 4.选中你要创建测试用例的方法。 5.OK