@@ -0,0 +1,1745 @@
+package com.njust.test;%0A%0Aimport java.util.stream.Stream;%0A%0Aimport org.junit.Assert;%0Aimport org.junit.Test;%0A%0Aimport lombok.Getter;%0A%0Apublic class EnumTest%0A%7B%0A%0A    @Test(expected = IllegalArgumentException.class)%0A    public void testBasic()%0A    %7B%0A        Assert.assertEquals(TypeEnum.valueOf(%22aaa%22), TypeEnum.AAA);%0A        Assert.assertEquals(TypeEnum.valueOf(%22bbb%22), TypeEnum.BBB);%0A    %7D%0A%0A    @Test%0A    public void testBasic2()%0A    %7B%0A        //enum.valueOf%E6%96%B9%E6%B3%95%E5%BF%85%E9%A1%BB%E4%BD%BF%E7%94%A8enum%E5%8F%98%E9%87%8F%E6%9C%AC%E8%BA%AB%E7%9A%84%E5%AE%9A%E4%B9%89%EF%BC%8C%E4%B8%8D%E6%98%AF%E5%B1%9E%E6%80%A7detail%EF%BC%8C%E8%80%8C%E4%B8%94%E5%A4%A7%E5%B0%8F%E5%86%99%E9%83%BD%E5%BF%85%E9%A1%BB%E4%B8%80%E6%A0%B7%0A        Assert.assertEquals(TypeEnum.valueOf(%22AAA%22), TypeEnum.AAA);%0A        Assert.assertEquals(TypeEnum.valueOf(%22BBB%22), TypeEnum.BBB);%0A    %7D%0A%0A    @Test(expected = IllegalArgumentException.class)%0A    public void testEqual01()%0A    %7B%0A        Assert.assertEquals(TypeEnum.valueOf(%22--aa%22), TypeEnum.AAA);%0A        Assert.assertEquals(TypeEnum.valueOf(%22--bb%22), TypeEnum.BBB);%0A    %7D%0A%0A    @Test%0A    public void testEqual02()%0A    %7B%0A        //2.%E5%88%A4%E6%96%AD%E7%9B%B8%E7%AD%89%E6%96%B9%E6%B3%951%E6%98%AF%E7%9B%B4%E6%8E%A5%E5%AD%97%E7%AC%A6%E4%B8%B2%E6%AF%94%E8%BE%83%EF%BC%9B2%E6%98%AF%E8%87%AA%E5%B7%B1%E5%86%99%E6%96%B9%E6%B3%95%E8%BD%AC%E6%8D%A2%E5%88%B0enum%E5%AF%B9%E8%B1%A1%0A        Assert.assertEquals(%22--aa%22, TypeEnum.AAA.getDetail());%0A        Assert.assertEquals(%22--bb%22, TypeEnum.BBB.getDetail());%0A    %7D%0A%0A    @Test%0A    public void testEqual03()%0A    %7B%0A        Assert.assertEquals(TypeEnum.from(%22--aa%22), TypeEnum.AAA);%0A        Assert.assertEquals(TypeEnum.from(%22--bb%22), TypeEnum.BBB);%0A    %7D%0A%0A    @Test%0A    public void illegal01()%0A    %7B%0A        TypeEnum.valueOf(%22***%22);%0A    %7D%0A%0A    enum TypeEnum%0A    %7B%0A        AAA(%22--aa%22),%0A        BBB(%22--bb%22);%0A%0A        @Getter%0A        private String detail;%0A%0A        TypeEnum(String detail)%0A        %7B%0A            this.detail = detail;%0A        %7D%0A%0A        public static TypeEnum from(String detail)%0A        %7B%0A            return Stream.of(values()).filter(n -%3E n.detail.equals(detail)).findFirst().orElse(null);%0A        %7D%0A    %7D%0A%7D%0A

Create EnumTest.java