         log.info(in: .view, "not yet configured")
         XCTAssertEqual(testLogger.last, "Nothing logged")
         
-        LogCentral.loggers = [testLogger.logger]
+        LogCentral.loggers = [testLogger]
         
         log.info(in: .view, "first log")
         XCTAssertEqual(testLogger.last, "[info] first log")

        }
    }
    
    lazy var logger: LogWriter = {
        return LogWriter(levels: levels, messageWriter: { (msg, lvl) in
            self.lastLog = (lvl, msg)
            self.lastError = nil
        }) { (error) in
            self.lastLog = nil
            self.lastError = error
        }
    }()
    
    init(_ levels: [LogLevel]) {
        self.levels = levels
    }
}

class LogCentralTests: XCTestCase {

    func testActivity() {
        let myActivity = Activity("MY_ACTIVITY", parent: .none)
        myActivity.active {

    }

    func testOneDualLevelLogger() {
        let infoAndDebugLogger = TestLogger([.info, .debug])
        
        log.info(in: .view, "not yet configured")
        XCTAssertEqual(infoAndDebugLogger.last, "Nothing logged")
        
        LogCentral.loggers = [infoAndDebugLogger]
        
        log.info(in: .view, "first log")
        XCTAssertEqual(infoAndDebugLogger.last, "[info] first log")
        
        log.debug(in: .view, "second log")
        XCTAssertEqual(infoAndDebugLogger.last, "[debug] second log")
    }
    
    func throwser() throws {
        throw TestError.test
    }
