mirror of
https://github.com/lightningdevkit/rust-lightning.git
synced 2025-02-25 15:20:24 +01:00
Correct test log printing due to inverted comparison
We changed the sort order of log levels to be more natural, but this comparison wasn't updated accordingly. Likely the reason it was left strange for so long is it also had the comparison argument ordering flipped.
This commit is contained in:
parent
e7560c83b4
commit
e8110ab33f
1 changed files with 1 additions and 1 deletions
|
@ -439,7 +439,7 @@ impl TestLogger {
|
||||||
impl Logger for TestLogger {
|
impl Logger for TestLogger {
|
||||||
fn log(&self, record: &Record) {
|
fn log(&self, record: &Record) {
|
||||||
*self.lines.lock().unwrap().entry((record.module_path.to_string(), format!("{}", record.args))).or_insert(0) += 1;
|
*self.lines.lock().unwrap().entry((record.module_path.to_string(), format!("{}", record.args))).or_insert(0) += 1;
|
||||||
if self.level >= record.level {
|
if record.level >= self.level {
|
||||||
println!("{:<5} {} [{} : {}, {}] {}", record.level.to_string(), self.id, record.module_path, record.file, record.line, record.args);
|
println!("{:<5} {} [{} : {}, {}] {}", record.level.to_string(), self.id, record.module_path, record.file, record.line, record.args);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue