mirror of
				https://github.com/astral-sh/ruff.git
				synced 2025-11-03 21:23:45 +00:00 
			
		
		
		
	
							parent
							
								
									c0c59b82ec
								
							
						
					
					
						commit
						6b8b318d6b
					
				
					 8 changed files with 7 additions and 7 deletions
				
			
		| 
						 | 
					@ -445,7 +445,7 @@ impl Notebook {
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
#[cfg(test)]
 | 
					#[cfg(test)]
 | 
				
			||||||
mod test {
 | 
					mod tests {
 | 
				
			||||||
    use std::path::Path;
 | 
					    use std::path::Path;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    use anyhow::Result;
 | 
					    use anyhow::Result;
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -126,7 +126,7 @@ pub(crate) fn remove_import_members(contents: &str, members: &[&str]) -> String
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
#[cfg(test)]
 | 
					#[cfg(test)]
 | 
				
			||||||
mod test {
 | 
					mod tests {
 | 
				
			||||||
    use crate::rules::pyupgrade::fixes::remove_import_members;
 | 
					    use crate::rules::pyupgrade::fixes::remove_import_members;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    #[test]
 | 
					    #[test]
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -477,7 +477,7 @@ pub(crate) fn printf_string_formatting(
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
#[cfg(test)]
 | 
					#[cfg(test)]
 | 
				
			||||||
mod test {
 | 
					mod tests {
 | 
				
			||||||
    use test_case::test_case;
 | 
					    use test_case::test_case;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    use super::*;
 | 
					    use super::*;
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -299,7 +299,7 @@ pub(crate) fn init(path: &Path) -> Result<()> {
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
#[cfg(test)]
 | 
					#[cfg(test)]
 | 
				
			||||||
mod test {
 | 
					mod tests {
 | 
				
			||||||
    use std::env::temp_dir;
 | 
					    use std::env::temp_dir;
 | 
				
			||||||
    use std::fs;
 | 
					    use std::fs;
 | 
				
			||||||
    use std::io::{self, Write};
 | 
					    use std::io::{self, Write};
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -346,7 +346,7 @@ pub(crate) fn lint_stdin(
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
#[cfg(test)]
 | 
					#[cfg(test)]
 | 
				
			||||||
mod test {
 | 
					mod tests {
 | 
				
			||||||
    use std::path::Path;
 | 
					    use std::path::Path;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    use crate::diagnostics::{load_jupyter_notebook, Diagnostics};
 | 
					    use crate::diagnostics::{load_jupyter_notebook, Diagnostics};
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -119,7 +119,7 @@ fn check_help_text() -> String {
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
#[cfg(test)]
 | 
					#[cfg(test)]
 | 
				
			||||||
mod test {
 | 
					mod tests {
 | 
				
			||||||
    use anyhow::Result;
 | 
					    use anyhow::Result;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    use crate::generate_all::Mode;
 | 
					    use crate::generate_all::Mode;
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -53,7 +53,7 @@ pub(crate) fn main(args: &Args) -> Result<()> {
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
#[cfg(test)]
 | 
					#[cfg(test)]
 | 
				
			||||||
mod test {
 | 
					mod tests {
 | 
				
			||||||
    use anyhow::Result;
 | 
					    use anyhow::Result;
 | 
				
			||||||
    use std::env;
 | 
					    use std::env;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue