mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-10 20:05:49 +00:00
Bug 727152 - Robocop: improve shutdown of mAsserter; r=jmaher
This commit is contained in:
parent
3070b4a349
commit
bdb85c6387
@ -10,8 +10,8 @@ public interface Assert {
|
||||
void dumpLog(String message, Throwable t);
|
||||
void setLogFile(String filename);
|
||||
void setTestName(String testName);
|
||||
void endTest();
|
||||
|
||||
void finalize();
|
||||
void ok(boolean condition, String name, String diag);
|
||||
void is(Object a, Object b, String name);
|
||||
void isnot(Object a, Object b, String name);
|
||||
|
@ -108,8 +108,7 @@ public class FennecMochitestAssert implements Assert {
|
||||
}
|
||||
}
|
||||
|
||||
public void finalize() {
|
||||
// It appears that we call finalize during cleanup, this might be an invalid assertion.
|
||||
public void endTest() {
|
||||
String message;
|
||||
|
||||
if (mLogTestName != "") {
|
||||
|
@ -31,7 +31,7 @@ public class FennecTalosAssert implements Assert {
|
||||
|
||||
public void setTestName(String testName) { }
|
||||
|
||||
public void finalize() { }
|
||||
public void endTest() { }
|
||||
|
||||
public void ok(boolean condition, String name, String diag) {
|
||||
if (!condition) {
|
||||
|
@ -105,7 +105,7 @@ abstract class BaseTest extends ActivityInstrumentationTestCase2<Activity> {
|
||||
@Override
|
||||
public void tearDown() throws Exception {
|
||||
try {
|
||||
mAsserter.finalize();
|
||||
mAsserter.endTest();
|
||||
mSolo.finalize();
|
||||
} catch (Throwable e) {
|
||||
e.printStackTrace();
|
||||
|
Loading…
Reference in New Issue
Block a user