Skip to content

Commit

Permalink
Final polishing. Identifier shown in the test logs.
Browse files Browse the repository at this point in the history
  • Loading branch information
william-hood committed Mar 17, 2023
1 parent 941dae6 commit 51627d1
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 18 deletions.
8 changes: 4 additions & 4 deletions A3_Hoodland_Projects_Test_Suite/src/TestDepictFailure.kt
Original file line number Diff line number Diff line change
Expand Up @@ -45,17 +45,17 @@ Index 46378 out of bounds for length 4
* TestDepictFailure.kt line 40 in method printSomeItem() of class hoodland.opensource.testsuite.TestDepictFailure
* TestDepictFailure.kt line 36 in method makeAndPrint() of class hoodland.opensource.testsuite.TestDepictFailure
* TestDepictFailure.kt line 66 in method setup() of class hoodland.opensource.testsuite.TestDepictFailure
* Test.kt line 377 in method runSetup${'$'}KoarseGrind() of class hoodland.opensource.koarsegrind.Test
* Test.kt line 428 in method runTest${'$'}KoarseGrind() of class hoodland.opensource.koarsegrind.Test
* Test.kt line 364 in method runSetup${'$'}KoarseGrind() of class hoodland.opensource.koarsegrind.Test
* Test.kt line 415 in method runTest${'$'}KoarseGrind() of class hoodland.opensource.koarsegrind.Test
* TestCategory.kt line 175 in method invoke() of class hoodland.opensource.koarsegrind.TestCategory${'$'}run${'$'}4
* TestCategory.kt line 57 in method invoke() of class hoodland.opensource.koarsegrind.TestCategory${'$'}run${'$'}4
* Thread.kt line 30 in method run() of class kotlin.concurrent.ThreadsKt${'$'}thread${'$'}thread${'$'}1
Exception
Just a fake exception to test this thing!
* TestDepictFailure.kt line 68 in method setup() of class hoodland.opensource.testsuite.TestDepictFailure
* Test.kt line 377 in method runSetup${'$'}KoarseGrind() of class hoodland.opensource.koarsegrind.Test
* Test.kt line 428 in method runTest${'$'}KoarseGrind() of class hoodland.opensource.koarsegrind.Test
* Test.kt line 364 in method runSetup${'$'}KoarseGrind() of class hoodland.opensource.koarsegrind.Test
* Test.kt line 415 in method runTest${'$'}KoarseGrind() of class hoodland.opensource.koarsegrind.Test
* TestCategory.kt line 175 in method invoke() of class hoodland.opensource.koarsegrind.TestCategory${'$'}run${'$'}4
* TestCategory.kt line 57 in method invoke() of class hoodland.opensource.koarsegrind.TestCategory${'$'}run${'$'}4
* Thread.kt line 30 in method run() of class kotlin.concurrent.ThreadsKt${'$'}thread${'$'}thread${'$'}1"""
Expand Down
15 changes: 1 addition & 14 deletions KoarseGrind/src/Test.kt
Original file line number Diff line number Diff line change
Expand Up @@ -136,19 +136,6 @@ abstract class Test (
*/
abstract fun performTest()

/*
private val categorization: String
get() {
val result = StringBuilder()
categories.forEach {
if (result.length > 0) { result.append('/') }
result.append(it)
}
return result.toString()
}
*/

/**
* log:
* Used to write information to Koarse Grind's HTML-based log file, as well as to the console. It is automatically
Expand Down Expand Up @@ -417,7 +404,7 @@ abstract class Test (
// Force the parent directory to exist...
File(expectedFileName).parentFile.mkdirs()

testContext = TestPhaseContext(Memoir(name, stdout, PrintWriter(expectedFileName), true, true, ::logHeader))
testContext = TestPhaseContext(Memoir(identifiedName, stdout, PrintWriter(expectedFileName), true, true, ::logHeader))

if (detailedDescription != UNSET_DESCRIPTION) {
testContext?.let { it.memoir.writeToHTML("<small><i>$detailedDescription</i></small>", EMOJI_TEXT_BLANK_LINE) }
Expand Down
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ Primary changes to this release are a new paradigm for Koarse Grind. **Refer to
- TestFactories no longer determine the name of the collection/category that the tests go in. The test programmer specifies this for each test.
- The root output folder can be changed from `$/Documents/TestResults` to the directory of your choice by setting `defaultParentFolder` before calling `TestProgram.run()`.
- Manually creating a "TestCollection" (now TestCategory) and populating it with tests is now prohibited. Use the CategoryPath field instead.
- This release of Koarse Grind is verified to work on Windows 11, macOS Ventura, and Linux Mint 21.1.

---

Expand Down

0 comments on commit 51627d1

Please sign in to comment.