aboutsummaryrefslogtreecommitdiffstats
path: root/src/test/java/com/jsyn/engine/TestFifo.java
diff options
context:
space:
mode:
authorPhil Burk <[email protected]>2021-08-29 09:23:58 -0700
committerPhil Burk <[email protected]>2021-08-29 09:26:54 -0700
commit911c8c9f292374b1668ce5e30a539f7e62f75369 (patch)
tree7f7f006c2d58a31fc142ca390c471905442933c8 /src/test/java/com/jsyn/engine/TestFifo.java
parentf4925c614cc6ace95049473734513bacc77afc85 (diff)
tests: fix unit tests
Add missing parameters. Create PseudoRandom. Do not run test that generates the WAV files. Fix hang in TestConnections. Fixes #97
Diffstat (limited to 'src/test/java/com/jsyn/engine/TestFifo.java')
-rw-r--r--src/test/java/com/jsyn/engine/TestFifo.java6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/test/java/com/jsyn/engine/TestFifo.java b/src/test/java/com/jsyn/engine/TestFifo.java
index d057e19..1c681fb 100644
--- a/src/test/java/com/jsyn/engine/TestFifo.java
+++ b/src/test/java/com/jsyn/engine/TestFifo.java
@@ -216,7 +216,7 @@ public class TestFifo {
@Test
public void testBlockReadAndWriteWaitStress() {
- final int chunk = 10000000; // 10 Megabytes
+ final int chunk = 3000000;
final AudioFifo fifo = new AudioFifo();
fifo.allocate(8);
@@ -236,7 +236,9 @@ public class TestFifo {
}
}).start();
- Thread watchdog = startWatchdog(10000);
+ // TODO Watchdog is apparently not working.
+ // I set the watchdog to be very short and it did not trigger.
+ Thread watchdog = startWatchdog(10 * 1000);
for (int i = 0; i < chunk; i++) {
assertEquals(value + i, fifo.read(), "reading back data");
}