-
Notifications
You must be signed in to change notification settings - Fork 56
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
12 changed files
with
208 additions
and
234 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
package com.pr.sepp.common.addin; | ||
|
||
public class FatherTest { | ||
private String name; | ||
|
||
public FatherTest() { | ||
System.out.println("--父类的无参构造函数--"); | ||
} | ||
|
||
public FatherTest(String name) { | ||
this.name = name; | ||
System.out.println("--父类的有参构造函数--" + this.name); | ||
} | ||
|
||
static { | ||
System.out.println("--父类的静态代码块--"); | ||
} | ||
{ | ||
System.out.println("--父类的非静态代码块--"); | ||
} | ||
|
||
public void speak() { | ||
System.out.println("--父类的方法--"); | ||
} | ||
|
||
// 加入一个main程序后 | ||
public static void main(String[] args) { | ||
System.out.println("--父类主程序--"); | ||
FatherTest father1 = new FatherTest(); | ||
FatherTest father = new FatherTest("父亲的名字"); | ||
father1.speak(); | ||
father.speak(); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
package com.pr.sepp.common.addin; | ||
|
||
public class SonTest extends FatherTest { | ||
private String name; | ||
static { | ||
System.out.println("--子类的静态代码块--"); | ||
} | ||
{ | ||
System.out.println("--子类的非静态代码块--"); | ||
} | ||
|
||
SonTest() { | ||
System.out.println("--子类的无参构造函数--"); | ||
} | ||
|
||
SonTest(String name) { | ||
this.name = name; | ||
System.out.println("--子类的有参构造函数--" + this.name); | ||
} | ||
|
||
@Override | ||
public void speak() { | ||
System.out.println("--子类Override了父类的方法--"); | ||
} | ||
|
||
// 然后再加入一个main函数 | ||
public static void main(String[] args) { | ||
System.out.println("--子类主程序--"); | ||
FatherTest father = new FatherTest("父亲的名字"); | ||
father.speak(); | ||
SonTest son = new SonTest("儿子的名字"); | ||
son.speak(); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
27 changes: 0 additions & 27 deletions
27
src/test/java/com/pr/sepp/common/service/AlertServiceTest.java
This file was deleted.
Oops, something went wrong.
24 changes: 24 additions & 0 deletions
24
src/test/java/com/pr/sepp/common/service/WarningServiceTest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
package com.pr.sepp.common.service; | ||
|
||
import com.pr.sepp.common.BaseServiceIntegrationTest; | ||
import com.pr.sepp.notify.warning.service.WarningService; | ||
import org.junit.Ignore; | ||
import org.junit.Test; | ||
import org.springframework.beans.factory.annotation.Autowired; | ||
import org.springframework.test.context.jdbc.Sql; | ||
|
||
import static org.junit.Assert.assertNull; | ||
|
||
public class WarningServiceTest extends BaseServiceIntegrationTest { | ||
|
||
@Autowired | ||
private WarningService warningService; | ||
|
||
@Test | ||
@Ignore | ||
@Sql(scripts = "/sql/init-warning.sql", executionPhase = Sql.ExecutionPhase.BEFORE_TEST_METHOD) | ||
public void testWarningListPaging() { | ||
assertNull("warningPageInfo"); | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.