mirror of
				https://github.com/zulip/zulip.git
				synced 2025-10-31 03:53:50 +00:00 
			
		
		
		
	python: Use ‘not in’ for more negated membership tests.
Fixes “E713 Test for membership should be `not in`” found by ruff (now that I’ve fixed it not to ignore scripts lacking a .py extension). Signed-off-by: Anders Kaseorg <anders@zulip.com>
This commit is contained in:
		
				
					committed by
					
						 Anders Kaseorg
						Anders Kaseorg
					
				
			
			
				
	
			
			
			
						parent
						
							4ba9853481
						
					
				
				
					commit
					b267b17677
				
			| @@ -19,7 +19,7 @@ states = { | ||||
|     3: "UNKNOWN", | ||||
| } | ||||
|  | ||||
| if "USER" in os.environ and not os.environ["USER"] in ["root", "rabbitmq"]: | ||||
| if "USER" in os.environ and os.environ["USER"] not in ["root", "rabbitmq"]: | ||||
|     print("This script must be run as the root or rabbitmq user") | ||||
|  | ||||
|  | ||||
|   | ||||
| @@ -399,7 +399,7 @@ def enforce_proper_coverage(coverage_json: Any) -> bool: | ||||
|     coverage_lost = False | ||||
|     for relative_path in enforce_fully_covered: | ||||
|         path = ROOT_DIR + "/" + relative_path | ||||
|         if not (path in coverage_json): | ||||
|         if path not in coverage_json: | ||||
|             coverage_lost = True | ||||
|             print_error(f"{relative_path} has no node test coverage") | ||||
|             continue | ||||
|   | ||||
		Reference in New Issue
	
	Block a user