Skip to content

Commit

Permalink
External unsafe row dequeue test extension
Browse files Browse the repository at this point in the history
  • Loading branch information
zecevicp committed Aug 10, 2018
1 parent 6a8ff5d commit 62a8071
Showing 1 changed file with 5 additions and 3 deletions.
Expand Up @@ -292,7 +292,7 @@ class ExternalAppendOnlyUnsafeRowArraySuite extends SparkFunSuite with LocalSpar
test(s"test dequeue with spill") {
withExternalArray(inMemoryThreshold = 2, spillThreshold = 3, true) { array =>
// insert 2 rows, iterate until the first row
populateRows(array, 10)
populateRows(array, 5)
assertSpill()

var iterator = array.generateIterator()
Expand All @@ -308,14 +308,16 @@ class ExternalAppendOnlyUnsafeRowArraySuite extends SparkFunSuite with LocalSpar
val third2 = array.dequeue().get
assert(third.equals(third2))

assert(array.length == 7)
assert(array.length == 2)

array.dequeue()

populateRows(array, 10)

array.dequeue()
array.dequeue()

assert(array.length == 15)
assert(array.length == 9)
}
}

Expand Down

0 comments on commit 62a8071

Please sign in to comment.