From 0c8f390e88bc6a2f87302cde29129bda296caab1 Mon Sep 17 00:00:00 2001 From: Brian Pellin Date: Tue, 10 Mar 2009 23:27:07 -0500 Subject: [PATCH] Remove broken test. --- .../tests/services/TimeoutServiceTest.java | 67 ------------------- 1 file changed, 67 deletions(-) delete mode 100644 tests/src/com/android/keepass/tests/services/TimeoutServiceTest.java diff --git a/tests/src/com/android/keepass/tests/services/TimeoutServiceTest.java b/tests/src/com/android/keepass/tests/services/TimeoutServiceTest.java deleted file mode 100644 index 56b33d04c..000000000 --- a/tests/src/com/android/keepass/tests/services/TimeoutServiceTest.java +++ /dev/null @@ -1,67 +0,0 @@ -/* Copyright 2009 Brian Pellin. - * - * This file is part of KeePassDroid. - * - * KeePassDroid is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * KeePassDroid is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with KeePassDroid. If not, see . - * - */ -package com.android.keepass.tests.services; - -import java.util.concurrent.Semaphore; -import java.util.concurrent.TimeUnit; - -import android.content.ComponentName; -import android.content.Context; -import android.content.Intent; -import android.content.ServiceConnection; -import android.os.IBinder; -import android.test.ServiceTestCase; - -import com.android.keepass.services.TimeoutService; - -public class TimeoutServiceTest extends ServiceTestCase { - public TimeoutServiceTest() { - super(TimeoutService.class); - } - - private TimeoutService mService; - - @Override - protected void setUp() throws Exception { - super.setUp(); - - startService(new Intent(getContext(), TimeoutService.class)); - mService = getService(); - assertNotNull(mService); - } - - - - public void testTimeout() { - assertFalse("Timeout is not set at the beginning.", mService.HasTimedOut() ); - - mService.startTimeout(1000); - - assertFalse("Timeout too early.", mService.HasTimedOut() ); - - try { - Thread.sleep(2000); - } catch (InterruptedException e) { - assertTrue("Thread interrupted.", false); - } - - assertTrue("Timeout was not set.", mService.HasTimedOut()); - - } -}