*not part of the buld*
blackConnect tests update git-svn-id: svn://10.0.0.236/trunk@99925 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
@@ -1,10 +1,26 @@
|
||||
/* -*- Mode: Java; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*-
|
||||
*
|
||||
*/
|
||||
|
||||
/*
|
||||
* ExecutionThread.java
|
||||
*/
|
||||
The contents of this file are subject to the Mozilla Public
|
||||
License Version 1.1 (the "License"); you may not use this file
|
||||
except in compliance with the License. You may obtain a copy of
|
||||
the License at http://www.mozilla.org/MPL/
|
||||
|
||||
Software distributed under the License is distributed on an "AS
|
||||
IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
|
||||
implied. See the License for the specific language governing
|
||||
rights and limitations under the License.
|
||||
|
||||
The Original Code is mozilla.org code.
|
||||
|
||||
The Initial Developer of the Original Code is Sun Microsystems,
|
||||
Inc. Portions created by Sun are
|
||||
Copyright (C) 1999 Sun Microsystems, Inc. All
|
||||
Rights Reserved.
|
||||
|
||||
Contributor(s):
|
||||
Client QA Team, St. Petersburg, Russia
|
||||
*/
|
||||
|
||||
import org.mozilla.xpcom.*;
|
||||
import java.util.Date;
|
||||
|
||||
@@ -34,14 +50,13 @@ public class ExecutionThread extends Thread {
|
||||
public int timeoutGen() {
|
||||
return (int)Math.round(Math.random()*MAX_TIMEOUT);
|
||||
}
|
||||
public void run(){
|
||||
public void run(int t, int s){
|
||||
try {
|
||||
if(timeout == Integer.MAX_VALUE) {
|
||||
timeout = timeoutGen();
|
||||
}
|
||||
System.out.println("ExecutionThread(" + getName() + ") sleep to " + timeout);
|
||||
sleep(timeout);
|
||||
component.execute(getName());
|
||||
component.execute(t,s);
|
||||
} catch (Exception e) {
|
||||
System.out.println("Execution thread had been interrupted");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user