mirror of
				https://github.com/esphome/esphome.git
				synced 2025-10-31 15:12:06 +00:00 
			
		
		
		
	Reduce LightCall memory usage by 50 bytes per call (#9333)
This commit is contained in:
		
							
								
								
									
										80
									
								
								tests/integration/fixtures/light_calls.yaml
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										80
									
								
								tests/integration/fixtures/light_calls.yaml
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,80 @@ | ||||
| esphome: | ||||
|   name: light-calls-test | ||||
| host: | ||||
| api:  # Port will be automatically injected | ||||
| logger: | ||||
|   level: DEBUG | ||||
|  | ||||
| # Test outputs for RGBCW light | ||||
| output: | ||||
|   - platform: template | ||||
|     id: test_red | ||||
|     type: float | ||||
|     write_action: | ||||
|       - logger.log: | ||||
|           format: "Red output: %.2f" | ||||
|           args: [state] | ||||
|   - platform: template | ||||
|     id: test_green | ||||
|     type: float | ||||
|     write_action: | ||||
|       - logger.log: | ||||
|           format: "Green output: %.2f" | ||||
|           args: [state] | ||||
|   - platform: template | ||||
|     id: test_blue | ||||
|     type: float | ||||
|     write_action: | ||||
|       - logger.log: | ||||
|           format: "Blue output: %.2f" | ||||
|           args: [state] | ||||
|   - platform: template | ||||
|     id: test_cold_white | ||||
|     type: float | ||||
|     write_action: | ||||
|       - logger.log: | ||||
|           format: "Cold white output: %.2f" | ||||
|           args: [state] | ||||
|   - platform: template | ||||
|     id: test_warm_white | ||||
|     type: float | ||||
|     write_action: | ||||
|       - logger.log: | ||||
|           format: "Warm white output: %.2f" | ||||
|           args: [state] | ||||
|  | ||||
| light: | ||||
|   - platform: rgbww | ||||
|     name: "Test RGBCW Light" | ||||
|     id: test_light | ||||
|     red: test_red | ||||
|     green: test_green | ||||
|     blue: test_blue | ||||
|     cold_white: test_cold_white | ||||
|     warm_white: test_warm_white | ||||
|     cold_white_color_temperature: 6536 K | ||||
|     warm_white_color_temperature: 2000 K | ||||
|     constant_brightness: true | ||||
|     effects: | ||||
|       - random: | ||||
|           name: "Random Effect" | ||||
|           transition_length: 100ms | ||||
|           update_interval: 200ms | ||||
|       - strobe: | ||||
|           name: "Strobe Effect" | ||||
|       - pulse: | ||||
|           name: "Pulse Effect" | ||||
|           transition_length: 100ms | ||||
|  | ||||
|   # Additional lights to test memory with multiple instances | ||||
|   - platform: rgb | ||||
|     name: "Test RGB Light" | ||||
|     id: test_rgb_light | ||||
|     red: test_red | ||||
|     green: test_green | ||||
|     blue: test_blue | ||||
|  | ||||
|   - platform: binary | ||||
|     name: "Test Binary Light" | ||||
|     id: test_binary_light | ||||
|     output: test_red | ||||
		Reference in New Issue
	
	Block a user