         isLibrary: Bool,
         wholeModuleOptimization: Bool
     ) {
+        assert(commands[name] == nil, "aleady had a command named '\(name)'")
         let tool = SwiftCompilerTool(
             inputs: inputs,
             outputs: outputs,

        inputs: [Node],
        outputs: [Node]
    ) {
        let tool = TestDiscoveryTool(inputs: inputs, outputs: outputs)
        commands[name] = Command(name: name, tool: tool)
    }

        inputs: [Node],
        outputs: [Node]
    ) {
        assert(commands[name] == nil, "aleady had a command named '\(name)'")
        let tool = PhonyTool(inputs: inputs, outputs: outputs)
        commands[name] = Command(name: name, tool: tool)
    }
