             case .usage:
                 usage()
         
+            case .listTests:
+                let testPath = try determineTestPath(opts: opts)
+                let testSuites = try getTestSuites(path: testPath)
+                // Print the tests.
+                for testSuite in testSuites {
+                    for testCase in testSuite.tests {
+                        for test in testCase.tests {
+                            print(testCase.name + "/" + test)
+                        }
+                        print()
+                    }
+                }
+
             case .run(let specifier):
                 let yamlPath = Path.join(opts.path.build, "\(configuration).yaml")
                 try build(YAMLPath: yamlPath, target: "test")

        #endif
    }
}

        switch self {
        case .testsExecutableNotFound:
            return "no tests found to execute, create a module in your `Tests' directory"
        case .invalidListTestJSONData:
            return "Invalid list test JSON structure."
        }
    }
}

private enum Mode: Argument, Equatable, CustomStringConvertible {
    case usage
    case listTests
    case run(String?)

    init?(argument: String, pop: () -> String?) throws {
        switch argument {
        case "--help", "-h":
            self = .usage
        case "-l", "--list-tests":
            self = .listTests
        case "-s", "--specifier":
            guard let specifier = pop() else { throw OptionParserError.expectedAssociatedValue(argument) }
            self = .run(specifier)
