From 290816be11016699c9413d2c62fb92149f201bb4 Mon Sep 17 00:00:00 2001 From: Anton Viktorov Date: Sun, 16 Jun 2024 09:50:00 +0200 Subject: [PATCH 01/15] VEML7700 Fix GCC build warnings (#6881) --- esphome/components/veml7700/veml7700.cpp | 2 +- esphome/components/veml7700/veml7700.h | 10 +++++----- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/esphome/components/veml7700/veml7700.cpp b/esphome/components/veml7700/veml7700.cpp index 68550811a1..a8c1411c68 100644 --- a/esphome/components/veml7700/veml7700.cpp +++ b/esphome/components/veml7700/veml7700.cpp @@ -243,7 +243,7 @@ ErrorCode VEML7700Component::configure_() { } PSMRegister psm{0}; - psm.PSM = PSM::PSM_MODE_1; + psm.PSM = PSMMode::PSM_MODE_1; psm.PSM_EN = false; ESP_LOGV(TAG, "Setting PSM to 0x%04X", psm.raw); err = this->write_register((uint8_t) CommandRegisters::PWR_SAVING, psm.raw_bytes, VEML_REG_SIZE); diff --git a/esphome/components/veml7700/veml7700.h b/esphome/components/veml7700/veml7700.h index fe5e1158e3..17fee6b851 100644 --- a/esphome/components/veml7700/veml7700.h +++ b/esphome/components/veml7700/veml7700.h @@ -24,7 +24,7 @@ enum class CommandRegisters : uint8_t { ALS_INT = 0x06 // R: ALS INT trigger event }; -enum Gain : uint8_t { +enum Gain : uint16_t { X_1 = 0, X_2 = 1, X_1_8 = 2, @@ -32,7 +32,7 @@ enum Gain : uint8_t { }; const uint8_t GAINS_COUNT = 4; -enum IntegrationTime : uint8_t { +enum IntegrationTime : uint16_t { INTEGRATION_TIME_25MS = 0b1100, INTEGRATION_TIME_50MS = 0b1000, INTEGRATION_TIME_100MS = 0b0000, @@ -42,14 +42,14 @@ enum IntegrationTime : uint8_t { }; const uint8_t INTEGRATION_TIMES_COUNT = 6; -enum Persistence : uint8_t { +enum Persistence : uint16_t { PERSISTENCE_1 = 0, PERSISTENCE_2 = 1, PERSISTENCE_4 = 2, PERSISTENCE_8 = 3, }; -enum PSM : uint8_t { +enum PSMMode : uint16_t { PSM_MODE_1 = 0, PSM_MODE_2 = 1, PSM_MODE_3 = 2, @@ -92,7 +92,7 @@ union PSMRegister { uint8_t raw_bytes[2]; struct { bool PSM_EN : 1; - uint8_t PSM : 2; + PSMMode PSM : 2; uint16_t reserved : 13; } __attribute__((packed)); }; From d49f2cbec80355694f046088ac0c35ef6483f77a Mon Sep 17 00:00:00 2001 From: Keith Burzinski Date: Sun, 16 Jun 2024 03:02:15 -0500 Subject: [PATCH 02/15] IDF 5 fixes for #6802 (#6911) --- esphome/components/ethernet/ethernet_component.cpp | 2 +- esphome/components/voice_assistant/voice_assistant.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/esphome/components/ethernet/ethernet_component.cpp b/esphome/components/ethernet/ethernet_component.cpp index 75bdd29be7..7370cb4b44 100644 --- a/esphome/components/ethernet/ethernet_component.cpp +++ b/esphome/components/ethernet/ethernet_component.cpp @@ -631,7 +631,7 @@ void EthernetComponent::write_phy_register_(esp_eth_mac_t *mac, PHYRegister regi ESPHL_ERROR_CHECK(err, "Writing PHY Register failed"); if (this->type_ == ETHERNET_TYPE_RTL8201 && register_data.page) { - ESP_LOGD(TAG, "Select PHY Register Page 0x%02" PRIX32, 0x0); + ESP_LOGD(TAG, "Select PHY Register Page 0x00"); err = mac->write_phy_reg(mac, this->phy_addr_, eth_phy_psr_reg_addr, 0x0); ESPHL_ERROR_CHECK(err, "Select PHY Register Page 0 failed"); } diff --git a/esphome/components/voice_assistant/voice_assistant.cpp b/esphome/components/voice_assistant/voice_assistant.cpp index 1fa8236cf4..8a8a9e92aa 100644 --- a/esphome/components/voice_assistant/voice_assistant.cpp +++ b/esphome/components/voice_assistant/voice_assistant.cpp @@ -799,7 +799,7 @@ void VoiceAssistant::on_audio(const api::VoiceAssistantAudio &msg) { this->speaker_buffer_index_ += msg.data.length(); this->speaker_buffer_size_ += msg.data.length(); this->speaker_bytes_received_ += msg.data.length(); - ESP_LOGV(TAG, "Received audio: %" PRId32 " bytes from API", msg.data.length()); + ESP_LOGV(TAG, "Received audio: %u bytes from API", msg.data.length()); } else { ESP_LOGE(TAG, "Cannot receive audio, buffer is full"); } From 253303f3a9f27012660e30b7745ddccd5a713715 Mon Sep 17 00:00:00 2001 From: Jesse Hills <3060199+jesserockz@users.noreply.github.com> Date: Mon, 17 Jun 2024 13:01:07 +1200 Subject: [PATCH 03/15] [ili9xxx] Fix init for GC9A01A (#6913) --- .../components/ili9xxx/ili9xxx_display.cpp | 20 ++++++++++++++++--- esphome/components/ili9xxx/ili9xxx_display.h | 3 ++- 2 files changed, 19 insertions(+), 4 deletions(-) diff --git a/esphome/components/ili9xxx/ili9xxx_display.cpp b/esphome/components/ili9xxx/ili9xxx_display.cpp index 21d46ea825..de03df5d41 100644 --- a/esphome/components/ili9xxx/ili9xxx_display.cpp +++ b/esphome/components/ili9xxx/ili9xxx_display.cpp @@ -34,8 +34,8 @@ void ILI9XXXDisplay::setup() { ESP_LOGD(TAG, "Setting up ILI9xxx"); this->setup_pins_(); - this->init_lcd_(this->init_sequence_); - this->init_lcd_(this->extra_init_sequence_.data()); + this->init_lcd(this->init_sequence_); + this->init_lcd(this->extra_init_sequence_.data()); switch (this->pixel_mode_) { case PIXEL_MODE_16: if (this->is_18bitdisplay_) { @@ -405,7 +405,7 @@ void ILI9XXXDisplay::reset_() { } } -void ILI9XXXDisplay::init_lcd_(const uint8_t *addr) { +void ILI9XXXDisplay::init_lcd(const uint8_t *addr) { if (addr == nullptr) return; uint8_t cmd, x, num_args; @@ -427,6 +427,20 @@ void ILI9XXXDisplay::init_lcd_(const uint8_t *addr) { } } +void ILI9XXXGC9A01A::init_lcd(const uint8_t *addr) { + if (addr == nullptr) + return; + uint8_t cmd, x, num_args; + while ((cmd = *addr++) != 0) { + x = *addr++; + num_args = x & 0x7F; + this->send_command(cmd, addr, num_args); + addr += num_args; + if (x & 0x80) + delay(150); // NOLINT + } +} + // Tell the display controller where we want to draw pixels. void ILI9XXXDisplay::set_addr_window_(uint16_t x1, uint16_t y1, uint16_t x2, uint16_t y2) { x1 += this->offset_x_; diff --git a/esphome/components/ili9xxx/ili9xxx_display.h b/esphome/components/ili9xxx/ili9xxx_display.h index 7a320dac7b..b60047a8c3 100644 --- a/esphome/components/ili9xxx/ili9xxx_display.h +++ b/esphome/components/ili9xxx/ili9xxx_display.h @@ -109,7 +109,7 @@ class ILI9XXXDisplay : public display::DisplayBuffer, virtual void set_madctl(); void display_(); - void init_lcd_(const uint8_t *addr); + virtual void init_lcd(const uint8_t *addr); void set_addr_window_(uint16_t x, uint16_t y, uint16_t x2, uint16_t y2); void reset_(); @@ -269,6 +269,7 @@ class ILI9XXXS3BoxLite : public ILI9XXXDisplay { class ILI9XXXGC9A01A : public ILI9XXXDisplay { public: ILI9XXXGC9A01A() : ILI9XXXDisplay(INITCMD_GC9A01A, 240, 240, true) {} + void init_lcd(const uint8_t *addr) override; }; //----------- ILI9XXX_24_TFT display -------------- From 6b89763ad61f4bd0ab5cb8d6417dd678972b6ed6 Mon Sep 17 00:00:00 2001 From: Jesse Hills <3060199+jesserockz@users.noreply.github.com> Date: Mon, 17 Jun 2024 13:20:04 +1200 Subject: [PATCH 04/15] [mqtt] Fix datetime copy pasta (#6914) --- esphome/components/mqtt/mqtt_datetime.cpp | 6 +++--- esphome/components/mqtt/mqtt_datetime.h | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/esphome/components/mqtt/mqtt_datetime.cpp b/esphome/components/mqtt/mqtt_datetime.cpp index 4fa44aafb8..4ae6d0d416 100644 --- a/esphome/components/mqtt/mqtt_datetime.cpp +++ b/esphome/components/mqtt/mqtt_datetime.cpp @@ -6,12 +6,12 @@ #include "mqtt_const.h" #ifdef USE_MQTT -#ifdef USE_DATETIME_TIME +#ifdef USE_DATETIME_DATETIME namespace esphome { namespace mqtt { -static const char *const TAG = "mqtt.datetime.time"; +static const char *const TAG = "mqtt.datetime.datetime"; using namespace esphome::datetime; @@ -80,5 +80,5 @@ bool MQTTDateTimeComponent::publish_state(uint16_t year, uint8_t month, uint8_t } // namespace mqtt } // namespace esphome -#endif // USE_DATETIME_TIME +#endif // USE_DATETIME_DATETIME #endif // USE_MQTT diff --git a/esphome/components/mqtt/mqtt_datetime.h b/esphome/components/mqtt/mqtt_datetime.h index f0d68ad2e1..ba81c06cb3 100644 --- a/esphome/components/mqtt/mqtt_datetime.h +++ b/esphome/components/mqtt/mqtt_datetime.h @@ -3,7 +3,7 @@ #include "esphome/core/defines.h" #ifdef USE_MQTT -#ifdef USE_DATETIME_TIME +#ifdef USE_DATETIME_DATETIME #include "esphome/components/datetime/datetime_entity.h" #include "mqtt_component.h" @@ -17,7 +17,7 @@ class MQTTDateTimeComponent : public mqtt::MQTTComponent { * * @param time The time entity. */ - explicit MQTTDateTimeComponent(datetime::DateTimeEntity *time); + explicit MQTTDateTimeComponent(datetime::DateTimeEntity *datetime); // ========== INTERNAL METHODS ========== // (In most use cases you won't need these) @@ -41,5 +41,5 @@ class MQTTDateTimeComponent : public mqtt::MQTTComponent { } // namespace mqtt } // namespace esphome -#endif // USE_DATETIME_DATE +#endif // USE_DATETIME_DATETIME #endif // USE_MQTT From eb50f0eafd7e920c7405ae476a6878e3c53ee6ba Mon Sep 17 00:00:00 2001 From: esphomebot Date: Thu, 13 Jun 2024 19:24:36 +1200 Subject: [PATCH 05/15] Synchronise Device Classes from Home Assistant (#6904) --- esphome/components/update/__init__.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/esphome/components/update/__init__.py b/esphome/components/update/__init__.py index ae3d5062ab..ea1cf778b6 100644 --- a/esphome/components/update/__init__.py +++ b/esphome/components/update/__init__.py @@ -7,6 +7,7 @@ from esphome.const import ( CONF_ID, CONF_MQTT_ID, CONF_WEB_SERVER_ID, + DEVICE_CLASS_EMPTY, DEVICE_CLASS_FIRMWARE, ) from esphome.core import CORE, coroutine_with_priority @@ -24,6 +25,7 @@ PerformAction = update_ns.class_("PerformAction", automation.Action) IsAvailableCondition = update_ns.class_("IsAvailableCondition", automation.Condition) DEVICE_CLASSES = [ + DEVICE_CLASS_EMPTY, DEVICE_CLASS_FIRMWARE, ] From 1e66241b2696c80f222dd853db76bd10acb48ac4 Mon Sep 17 00:00:00 2001 From: Jesse Hills <3060199+jesserockz@users.noreply.github.com> Date: Mon, 17 Jun 2024 13:01:07 +1200 Subject: [PATCH 06/15] [ili9xxx] Fix init for GC9A01A (#6913) --- .../components/ili9xxx/ili9xxx_display.cpp | 20 ++++++++++++++++--- esphome/components/ili9xxx/ili9xxx_display.h | 3 ++- 2 files changed, 19 insertions(+), 4 deletions(-) diff --git a/esphome/components/ili9xxx/ili9xxx_display.cpp b/esphome/components/ili9xxx/ili9xxx_display.cpp index 21d46ea825..de03df5d41 100644 --- a/esphome/components/ili9xxx/ili9xxx_display.cpp +++ b/esphome/components/ili9xxx/ili9xxx_display.cpp @@ -34,8 +34,8 @@ void ILI9XXXDisplay::setup() { ESP_LOGD(TAG, "Setting up ILI9xxx"); this->setup_pins_(); - this->init_lcd_(this->init_sequence_); - this->init_lcd_(this->extra_init_sequence_.data()); + this->init_lcd(this->init_sequence_); + this->init_lcd(this->extra_init_sequence_.data()); switch (this->pixel_mode_) { case PIXEL_MODE_16: if (this->is_18bitdisplay_) { @@ -405,7 +405,7 @@ void ILI9XXXDisplay::reset_() { } } -void ILI9XXXDisplay::init_lcd_(const uint8_t *addr) { +void ILI9XXXDisplay::init_lcd(const uint8_t *addr) { if (addr == nullptr) return; uint8_t cmd, x, num_args; @@ -427,6 +427,20 @@ void ILI9XXXDisplay::init_lcd_(const uint8_t *addr) { } } +void ILI9XXXGC9A01A::init_lcd(const uint8_t *addr) { + if (addr == nullptr) + return; + uint8_t cmd, x, num_args; + while ((cmd = *addr++) != 0) { + x = *addr++; + num_args = x & 0x7F; + this->send_command(cmd, addr, num_args); + addr += num_args; + if (x & 0x80) + delay(150); // NOLINT + } +} + // Tell the display controller where we want to draw pixels. void ILI9XXXDisplay::set_addr_window_(uint16_t x1, uint16_t y1, uint16_t x2, uint16_t y2) { x1 += this->offset_x_; diff --git a/esphome/components/ili9xxx/ili9xxx_display.h b/esphome/components/ili9xxx/ili9xxx_display.h index 7a320dac7b..b60047a8c3 100644 --- a/esphome/components/ili9xxx/ili9xxx_display.h +++ b/esphome/components/ili9xxx/ili9xxx_display.h @@ -109,7 +109,7 @@ class ILI9XXXDisplay : public display::DisplayBuffer, virtual void set_madctl(); void display_(); - void init_lcd_(const uint8_t *addr); + virtual void init_lcd(const uint8_t *addr); void set_addr_window_(uint16_t x, uint16_t y, uint16_t x2, uint16_t y2); void reset_(); @@ -269,6 +269,7 @@ class ILI9XXXS3BoxLite : public ILI9XXXDisplay { class ILI9XXXGC9A01A : public ILI9XXXDisplay { public: ILI9XXXGC9A01A() : ILI9XXXDisplay(INITCMD_GC9A01A, 240, 240, true) {} + void init_lcd(const uint8_t *addr) override; }; //----------- ILI9XXX_24_TFT display -------------- From 65638bf61420b2278b5043fc98f713475be2b749 Mon Sep 17 00:00:00 2001 From: Jesse Hills <3060199+jesserockz@users.noreply.github.com> Date: Mon, 17 Jun 2024 13:20:04 +1200 Subject: [PATCH 07/15] [mqtt] Fix datetime copy pasta (#6914) --- esphome/components/mqtt/mqtt_datetime.cpp | 6 +++--- esphome/components/mqtt/mqtt_datetime.h | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/esphome/components/mqtt/mqtt_datetime.cpp b/esphome/components/mqtt/mqtt_datetime.cpp index 4fa44aafb8..4ae6d0d416 100644 --- a/esphome/components/mqtt/mqtt_datetime.cpp +++ b/esphome/components/mqtt/mqtt_datetime.cpp @@ -6,12 +6,12 @@ #include "mqtt_const.h" #ifdef USE_MQTT -#ifdef USE_DATETIME_TIME +#ifdef USE_DATETIME_DATETIME namespace esphome { namespace mqtt { -static const char *const TAG = "mqtt.datetime.time"; +static const char *const TAG = "mqtt.datetime.datetime"; using namespace esphome::datetime; @@ -80,5 +80,5 @@ bool MQTTDateTimeComponent::publish_state(uint16_t year, uint8_t month, uint8_t } // namespace mqtt } // namespace esphome -#endif // USE_DATETIME_TIME +#endif // USE_DATETIME_DATETIME #endif // USE_MQTT diff --git a/esphome/components/mqtt/mqtt_datetime.h b/esphome/components/mqtt/mqtt_datetime.h index f0d68ad2e1..ba81c06cb3 100644 --- a/esphome/components/mqtt/mqtt_datetime.h +++ b/esphome/components/mqtt/mqtt_datetime.h @@ -3,7 +3,7 @@ #include "esphome/core/defines.h" #ifdef USE_MQTT -#ifdef USE_DATETIME_TIME +#ifdef USE_DATETIME_DATETIME #include "esphome/components/datetime/datetime_entity.h" #include "mqtt_component.h" @@ -17,7 +17,7 @@ class MQTTDateTimeComponent : public mqtt::MQTTComponent { * * @param time The time entity. */ - explicit MQTTDateTimeComponent(datetime::DateTimeEntity *time); + explicit MQTTDateTimeComponent(datetime::DateTimeEntity *datetime); // ========== INTERNAL METHODS ========== // (In most use cases you won't need these) @@ -41,5 +41,5 @@ class MQTTDateTimeComponent : public mqtt::MQTTComponent { } // namespace mqtt } // namespace esphome -#endif // USE_DATETIME_DATE +#endif // USE_DATETIME_DATETIME #endif // USE_MQTT From 25a3db1637d82fbc36a45c0e1d68f0bee7748718 Mon Sep 17 00:00:00 2001 From: Jesse Hills <3060199+jesserockz@users.noreply.github.com> Date: Mon, 17 Jun 2024 15:35:53 +1200 Subject: [PATCH 08/15] Bump version to 2024.6.0b3 --- esphome/const.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/esphome/const.py b/esphome/const.py index e2dc5c259a..a0fe325282 100644 --- a/esphome/const.py +++ b/esphome/const.py @@ -1,6 +1,6 @@ """Constants used by esphome.""" -__version__ = "2024.6.0b2" +__version__ = "2024.6.0b3" ALLOWED_NAME_CHARS = "abcdefghijklmnopqrstuvwxyz0123456789-_" VALID_SUBSTITUTIONS_CHARACTERS = ( From 51c5d1714cb8ee434b1c64d50280e328a11f4abf Mon Sep 17 00:00:00 2001 From: Giel van Schijndel Date: Mon, 17 Jun 2024 07:48:56 +0200 Subject: [PATCH 09/15] fix(dallas): make recovery time for 1-bit equal to that of 0-bit (#6763) --- esphome/components/gpio/one_wire/gpio_one_wire.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/esphome/components/gpio/one_wire/gpio_one_wire.cpp b/esphome/components/gpio/one_wire/gpio_one_wire.cpp index f47e8d58e3..34c2cf3c29 100644 --- a/esphome/components/gpio/one_wire/gpio_one_wire.cpp +++ b/esphome/components/gpio/one_wire/gpio_one_wire.cpp @@ -60,7 +60,7 @@ void HOT IRAM_ATTR GPIOOneWireBus::write_bit_(bool bit) { // recovery time: t_rec: min=1µs // ds18b20 appears to read the bus after roughly 14µs uint32_t delay0 = bit ? 6 : 60; - uint32_t delay1 = bit ? 54 : 5; + uint32_t delay1 = bit ? 59 : 5; // delay A/C delayMicroseconds(delay0); From 015cd42a2ed8197e189cc851aea0207bb0fd2b6e Mon Sep 17 00:00:00 2001 From: Keith Burzinski Date: Mon, 17 Jun 2024 02:06:25 -0500 Subject: [PATCH 10/15] [CI-ethernet] Add/fix/organize/clean up ethernet component tests (#6916) --- ...{lan8720.esp32-idf.yaml => common-dp83848.yaml} | 2 +- .../{lan8720.esp32.yaml => common-ip101.yaml} | 2 +- tests/components/ethernet/common-jl1101.yaml | 12 ++++++++++++ tests/components/ethernet/common-ksz8081.yaml | 12 ++++++++++++ tests/components/ethernet/common-ksz8081rna.yaml | 12 ++++++++++++ .../ethernet/{common.yaml => common-lan8720.yaml} | 0 tests/components/ethernet/common-rtl8201.yaml | 12 ++++++++++++ .../{w5500.esp32.yaml => common-w5500.yaml} | 12 ++++++------ .../ethernet/test-dp83848.esp32-idf.yaml | 1 + tests/components/ethernet/test-dp83848.esp32.yaml | 1 + .../components/ethernet/test-ip101.esp32-idf.yaml | 1 + tests/components/ethernet/test-ip101.esp32.yaml | 1 + .../components/ethernet/test-jl1101.esp32-idf.yaml | 1 + tests/components/ethernet/test-jl1101.esp32.yaml | 1 + .../ethernet/test-ksz8081.esp32-idf.yaml | 1 + tests/components/ethernet/test-ksz8081.esp32.yaml | 1 + .../ethernet/test-ksz8081rna.esp32-idf.yaml | 1 + .../components/ethernet/test-ksz8081rna.esp32.yaml | 1 + .../ethernet/test-lan8720.esp32-idf.yaml | 1 + tests/components/ethernet/test-lan8720.esp32.yaml | 1 + .../ethernet/test-rtl8201.esp32-idf.yaml | 1 + tests/components/ethernet/test-rtl8201.esp32.yaml | 1 + .../components/ethernet/test-w5500.esp32-idf.yaml | 1 + tests/components/ethernet/test-w5500.esp32.yaml | 1 + tests/components/ethernet/test.esp32-idf.yaml | 1 - tests/components/ethernet/test.esp32.yaml | 1 - tests/components/ethernet/w5500.esp32-idf.yaml | 14 -------------- 27 files changed, 72 insertions(+), 24 deletions(-) rename tests/components/ethernet/{lan8720.esp32-idf.yaml => common-dp83848.yaml} (92%) rename tests/components/ethernet/{lan8720.esp32.yaml => common-ip101.yaml} (92%) create mode 100644 tests/components/ethernet/common-jl1101.yaml create mode 100644 tests/components/ethernet/common-ksz8081.yaml create mode 100644 tests/components/ethernet/common-ksz8081rna.yaml rename tests/components/ethernet/{common.yaml => common-lan8720.yaml} (100%) create mode 100644 tests/components/ethernet/common-rtl8201.yaml rename tests/components/ethernet/{w5500.esp32.yaml => common-w5500.yaml} (57%) create mode 100644 tests/components/ethernet/test-dp83848.esp32-idf.yaml create mode 100644 tests/components/ethernet/test-dp83848.esp32.yaml create mode 100644 tests/components/ethernet/test-ip101.esp32-idf.yaml create mode 100644 tests/components/ethernet/test-ip101.esp32.yaml create mode 100644 tests/components/ethernet/test-jl1101.esp32-idf.yaml create mode 100644 tests/components/ethernet/test-jl1101.esp32.yaml create mode 100644 tests/components/ethernet/test-ksz8081.esp32-idf.yaml create mode 100644 tests/components/ethernet/test-ksz8081.esp32.yaml create mode 100644 tests/components/ethernet/test-ksz8081rna.esp32-idf.yaml create mode 100644 tests/components/ethernet/test-ksz8081rna.esp32.yaml create mode 100644 tests/components/ethernet/test-lan8720.esp32-idf.yaml create mode 100644 tests/components/ethernet/test-lan8720.esp32.yaml create mode 100644 tests/components/ethernet/test-rtl8201.esp32-idf.yaml create mode 100644 tests/components/ethernet/test-rtl8201.esp32.yaml create mode 100644 tests/components/ethernet/test-w5500.esp32-idf.yaml create mode 100644 tests/components/ethernet/test-w5500.esp32.yaml delete mode 100644 tests/components/ethernet/test.esp32-idf.yaml delete mode 100644 tests/components/ethernet/test.esp32.yaml delete mode 100644 tests/components/ethernet/w5500.esp32-idf.yaml diff --git a/tests/components/ethernet/lan8720.esp32-idf.yaml b/tests/components/ethernet/common-dp83848.yaml similarity index 92% rename from tests/components/ethernet/lan8720.esp32-idf.yaml rename to tests/components/ethernet/common-dp83848.yaml index b9ed9cb036..5b6ed3e8d0 100644 --- a/tests/components/ethernet/lan8720.esp32-idf.yaml +++ b/tests/components/ethernet/common-dp83848.yaml @@ -1,5 +1,5 @@ ethernet: - type: LAN8720 + type: DP83848 mdc_pin: 23 mdio_pin: 25 clk_mode: GPIO0_IN diff --git a/tests/components/ethernet/lan8720.esp32.yaml b/tests/components/ethernet/common-ip101.yaml similarity index 92% rename from tests/components/ethernet/lan8720.esp32.yaml rename to tests/components/ethernet/common-ip101.yaml index b9ed9cb036..5ca369cce1 100644 --- a/tests/components/ethernet/lan8720.esp32.yaml +++ b/tests/components/ethernet/common-ip101.yaml @@ -1,5 +1,5 @@ ethernet: - type: LAN8720 + type: IP101 mdc_pin: 23 mdio_pin: 25 clk_mode: GPIO0_IN diff --git a/tests/components/ethernet/common-jl1101.yaml b/tests/components/ethernet/common-jl1101.yaml new file mode 100644 index 0000000000..639542d807 --- /dev/null +++ b/tests/components/ethernet/common-jl1101.yaml @@ -0,0 +1,12 @@ +ethernet: + type: JL1101 + mdc_pin: 23 + mdio_pin: 25 + clk_mode: GPIO0_IN + phy_addr: 0 + power_pin: 26 + manual_ip: + static_ip: 192.168.178.56 + gateway: 192.168.178.1 + subnet: 255.255.255.0 + domain: .local diff --git a/tests/components/ethernet/common-ksz8081.yaml b/tests/components/ethernet/common-ksz8081.yaml new file mode 100644 index 0000000000..167606a1eb --- /dev/null +++ b/tests/components/ethernet/common-ksz8081.yaml @@ -0,0 +1,12 @@ +ethernet: + type: KSZ8081 + mdc_pin: 23 + mdio_pin: 25 + clk_mode: GPIO0_IN + phy_addr: 0 + power_pin: 26 + manual_ip: + static_ip: 192.168.178.56 + gateway: 192.168.178.1 + subnet: 255.255.255.0 + domain: .local diff --git a/tests/components/ethernet/common-ksz8081rna.yaml b/tests/components/ethernet/common-ksz8081rna.yaml new file mode 100644 index 0000000000..f506906b1b --- /dev/null +++ b/tests/components/ethernet/common-ksz8081rna.yaml @@ -0,0 +1,12 @@ +ethernet: + type: KSZ8081RNA + mdc_pin: 23 + mdio_pin: 25 + clk_mode: GPIO0_IN + phy_addr: 0 + power_pin: 26 + manual_ip: + static_ip: 192.168.178.56 + gateway: 192.168.178.1 + subnet: 255.255.255.0 + domain: .local diff --git a/tests/components/ethernet/common.yaml b/tests/components/ethernet/common-lan8720.yaml similarity index 100% rename from tests/components/ethernet/common.yaml rename to tests/components/ethernet/common-lan8720.yaml diff --git a/tests/components/ethernet/common-rtl8201.yaml b/tests/components/ethernet/common-rtl8201.yaml new file mode 100644 index 0000000000..43842e7c9f --- /dev/null +++ b/tests/components/ethernet/common-rtl8201.yaml @@ -0,0 +1,12 @@ +ethernet: + type: RTL8201 + mdc_pin: 23 + mdio_pin: 25 + clk_mode: GPIO0_IN + phy_addr: 0 + power_pin: 26 + manual_ip: + static_ip: 192.168.178.56 + gateway: 192.168.178.1 + subnet: 255.255.255.0 + domain: .local diff --git a/tests/components/ethernet/w5500.esp32.yaml b/tests/components/ethernet/common-w5500.yaml similarity index 57% rename from tests/components/ethernet/w5500.esp32.yaml rename to tests/components/ethernet/common-w5500.yaml index 6fdccb36e3..76661a75c3 100644 --- a/tests/components/ethernet/w5500.esp32.yaml +++ b/tests/components/ethernet/common-w5500.yaml @@ -1,11 +1,11 @@ ethernet: type: W5500 - clk_pin: GPIO19 - mosi_pin: GPIO21 - miso_pin: GPIO23 - cs_pin: GPIO18 - interrupt_pin: GPIO36 - reset_pin: GPIO22 + clk_pin: 19 + mosi_pin: 21 + miso_pin: 23 + cs_pin: 18 + interrupt_pin: 36 + reset_pin: 22 clock_speed: 10Mhz manual_ip: static_ip: 192.168.178.56 diff --git a/tests/components/ethernet/test-dp83848.esp32-idf.yaml b/tests/components/ethernet/test-dp83848.esp32-idf.yaml new file mode 100644 index 0000000000..906bfba17c --- /dev/null +++ b/tests/components/ethernet/test-dp83848.esp32-idf.yaml @@ -0,0 +1 @@ +<<: !include common-dp83848.yaml diff --git a/tests/components/ethernet/test-dp83848.esp32.yaml b/tests/components/ethernet/test-dp83848.esp32.yaml new file mode 100644 index 0000000000..906bfba17c --- /dev/null +++ b/tests/components/ethernet/test-dp83848.esp32.yaml @@ -0,0 +1 @@ +<<: !include common-dp83848.yaml diff --git a/tests/components/ethernet/test-ip101.esp32-idf.yaml b/tests/components/ethernet/test-ip101.esp32-idf.yaml new file mode 100644 index 0000000000..e52329d7ea --- /dev/null +++ b/tests/components/ethernet/test-ip101.esp32-idf.yaml @@ -0,0 +1 @@ +<<: !include common-ip101.yaml diff --git a/tests/components/ethernet/test-ip101.esp32.yaml b/tests/components/ethernet/test-ip101.esp32.yaml new file mode 100644 index 0000000000..e52329d7ea --- /dev/null +++ b/tests/components/ethernet/test-ip101.esp32.yaml @@ -0,0 +1 @@ +<<: !include common-ip101.yaml diff --git a/tests/components/ethernet/test-jl1101.esp32-idf.yaml b/tests/components/ethernet/test-jl1101.esp32-idf.yaml new file mode 100644 index 0000000000..95d8cd1f21 --- /dev/null +++ b/tests/components/ethernet/test-jl1101.esp32-idf.yaml @@ -0,0 +1 @@ +<<: !include common-jl1101.yaml diff --git a/tests/components/ethernet/test-jl1101.esp32.yaml b/tests/components/ethernet/test-jl1101.esp32.yaml new file mode 100644 index 0000000000..95d8cd1f21 --- /dev/null +++ b/tests/components/ethernet/test-jl1101.esp32.yaml @@ -0,0 +1 @@ +<<: !include common-jl1101.yaml diff --git a/tests/components/ethernet/test-ksz8081.esp32-idf.yaml b/tests/components/ethernet/test-ksz8081.esp32-idf.yaml new file mode 100644 index 0000000000..8f3c750c77 --- /dev/null +++ b/tests/components/ethernet/test-ksz8081.esp32-idf.yaml @@ -0,0 +1 @@ +<<: !include common-ksz8081.yaml diff --git a/tests/components/ethernet/test-ksz8081.esp32.yaml b/tests/components/ethernet/test-ksz8081.esp32.yaml new file mode 100644 index 0000000000..8f3c750c77 --- /dev/null +++ b/tests/components/ethernet/test-ksz8081.esp32.yaml @@ -0,0 +1 @@ +<<: !include common-ksz8081.yaml diff --git a/tests/components/ethernet/test-ksz8081rna.esp32-idf.yaml b/tests/components/ethernet/test-ksz8081rna.esp32-idf.yaml new file mode 100644 index 0000000000..a48e591996 --- /dev/null +++ b/tests/components/ethernet/test-ksz8081rna.esp32-idf.yaml @@ -0,0 +1 @@ +<<: !include common-ksz8081rna.yaml diff --git a/tests/components/ethernet/test-ksz8081rna.esp32.yaml b/tests/components/ethernet/test-ksz8081rna.esp32.yaml new file mode 100644 index 0000000000..a48e591996 --- /dev/null +++ b/tests/components/ethernet/test-ksz8081rna.esp32.yaml @@ -0,0 +1 @@ +<<: !include common-ksz8081rna.yaml diff --git a/tests/components/ethernet/test-lan8720.esp32-idf.yaml b/tests/components/ethernet/test-lan8720.esp32-idf.yaml new file mode 100644 index 0000000000..3df9ac874a --- /dev/null +++ b/tests/components/ethernet/test-lan8720.esp32-idf.yaml @@ -0,0 +1 @@ +<<: !include common-lan8720.yaml diff --git a/tests/components/ethernet/test-lan8720.esp32.yaml b/tests/components/ethernet/test-lan8720.esp32.yaml new file mode 100644 index 0000000000..3df9ac874a --- /dev/null +++ b/tests/components/ethernet/test-lan8720.esp32.yaml @@ -0,0 +1 @@ +<<: !include common-lan8720.yaml diff --git a/tests/components/ethernet/test-rtl8201.esp32-idf.yaml b/tests/components/ethernet/test-rtl8201.esp32-idf.yaml new file mode 100644 index 0000000000..e69f88dc94 --- /dev/null +++ b/tests/components/ethernet/test-rtl8201.esp32-idf.yaml @@ -0,0 +1 @@ +<<: !include common-rtl8201.yaml diff --git a/tests/components/ethernet/test-rtl8201.esp32.yaml b/tests/components/ethernet/test-rtl8201.esp32.yaml new file mode 100644 index 0000000000..e69f88dc94 --- /dev/null +++ b/tests/components/ethernet/test-rtl8201.esp32.yaml @@ -0,0 +1 @@ +<<: !include common-rtl8201.yaml diff --git a/tests/components/ethernet/test-w5500.esp32-idf.yaml b/tests/components/ethernet/test-w5500.esp32-idf.yaml new file mode 100644 index 0000000000..36f1b5365f --- /dev/null +++ b/tests/components/ethernet/test-w5500.esp32-idf.yaml @@ -0,0 +1 @@ +<<: !include common-w5500.yaml diff --git a/tests/components/ethernet/test-w5500.esp32.yaml b/tests/components/ethernet/test-w5500.esp32.yaml new file mode 100644 index 0000000000..36f1b5365f --- /dev/null +++ b/tests/components/ethernet/test-w5500.esp32.yaml @@ -0,0 +1 @@ +<<: !include common-w5500.yaml diff --git a/tests/components/ethernet/test.esp32-idf.yaml b/tests/components/ethernet/test.esp32-idf.yaml deleted file mode 100644 index dade44d145..0000000000 --- a/tests/components/ethernet/test.esp32-idf.yaml +++ /dev/null @@ -1 +0,0 @@ -<<: !include common.yaml diff --git a/tests/components/ethernet/test.esp32.yaml b/tests/components/ethernet/test.esp32.yaml deleted file mode 100644 index dade44d145..0000000000 --- a/tests/components/ethernet/test.esp32.yaml +++ /dev/null @@ -1 +0,0 @@ -<<: !include common.yaml diff --git a/tests/components/ethernet/w5500.esp32-idf.yaml b/tests/components/ethernet/w5500.esp32-idf.yaml deleted file mode 100644 index 6fdccb36e3..0000000000 --- a/tests/components/ethernet/w5500.esp32-idf.yaml +++ /dev/null @@ -1,14 +0,0 @@ -ethernet: - type: W5500 - clk_pin: GPIO19 - mosi_pin: GPIO21 - miso_pin: GPIO23 - cs_pin: GPIO18 - interrupt_pin: GPIO36 - reset_pin: GPIO22 - clock_speed: 10Mhz - manual_ip: - static_ip: 192.168.178.56 - gateway: 192.168.178.1 - subnet: 255.255.255.0 - domain: .local From 67d8c7c69164c48debffff6868c2dc9282ffc37b Mon Sep 17 00:00:00 2001 From: Keith Burzinski Date: Mon, 17 Jun 2024 02:14:19 -0500 Subject: [PATCH 11/15] [CI-a01nyub] Consolidate test files (#6917) --- tests/components/a01nyub/common.yaml | 11 +++++++++++ tests/components/a01nyub/test.esp32-c3-idf.yaml | 16 ++++------------ tests/components/a01nyub/test.esp32-c3.yaml | 16 ++++------------ tests/components/a01nyub/test.esp32-idf.yaml | 16 ++++------------ tests/components/a01nyub/test.esp32.yaml | 16 ++++------------ tests/components/a01nyub/test.esp8266.yaml | 16 ++++------------ tests/components/a01nyub/test.rp2040.yaml | 16 ++++------------ 7 files changed, 35 insertions(+), 72 deletions(-) create mode 100644 tests/components/a01nyub/common.yaml diff --git a/tests/components/a01nyub/common.yaml b/tests/components/a01nyub/common.yaml new file mode 100644 index 0000000000..0717acfff7 --- /dev/null +++ b/tests/components/a01nyub/common.yaml @@ -0,0 +1,11 @@ +uart: + - id: uart_a01nyub + tx_pin: ${tx_pin} + rx_pin: ${rx_pin} + baud_rate: 9600 + +sensor: + - platform: a01nyub + id: a01nyub_sensor + name: a01nyub Distance + uart_id: uart_a01nyub diff --git a/tests/components/a01nyub/test.esp32-c3-idf.yaml b/tests/components/a01nyub/test.esp32-c3-idf.yaml index 3132f77136..b516342f3b 100644 --- a/tests/components/a01nyub/test.esp32-c3-idf.yaml +++ b/tests/components/a01nyub/test.esp32-c3-idf.yaml @@ -1,13 +1,5 @@ -uart: - - id: uart_a01nyub - tx_pin: - number: 4 - rx_pin: - number: 5 - baud_rate: 9600 +substitutions: + tx_pin: GPIO4 + rx_pin: GPIO5 -sensor: - - platform: a01nyub - id: a01nyub_sensor - name: a01nyub Distance - uart_id: uart_a01nyub +<<: !include common.yaml diff --git a/tests/components/a01nyub/test.esp32-c3.yaml b/tests/components/a01nyub/test.esp32-c3.yaml index 3132f77136..b516342f3b 100644 --- a/tests/components/a01nyub/test.esp32-c3.yaml +++ b/tests/components/a01nyub/test.esp32-c3.yaml @@ -1,13 +1,5 @@ -uart: - - id: uart_a01nyub - tx_pin: - number: 4 - rx_pin: - number: 5 - baud_rate: 9600 +substitutions: + tx_pin: GPIO4 + rx_pin: GPIO5 -sensor: - - platform: a01nyub - id: a01nyub_sensor - name: a01nyub Distance - uart_id: uart_a01nyub +<<: !include common.yaml diff --git a/tests/components/a01nyub/test.esp32-idf.yaml b/tests/components/a01nyub/test.esp32-idf.yaml index 79fc9c5fbf..f486544afa 100644 --- a/tests/components/a01nyub/test.esp32-idf.yaml +++ b/tests/components/a01nyub/test.esp32-idf.yaml @@ -1,13 +1,5 @@ -uart: - - id: uart_a01nyub - tx_pin: - number: 17 - rx_pin: - number: 16 - baud_rate: 9600 +substitutions: + tx_pin: GPIO17 + rx_pin: GPIO16 -sensor: - - platform: a01nyub - id: a01nyub_sensor - name: a01nyub Distance - uart_id: uart_a01nyub +<<: !include common.yaml diff --git a/tests/components/a01nyub/test.esp32.yaml b/tests/components/a01nyub/test.esp32.yaml index 79fc9c5fbf..f486544afa 100644 --- a/tests/components/a01nyub/test.esp32.yaml +++ b/tests/components/a01nyub/test.esp32.yaml @@ -1,13 +1,5 @@ -uart: - - id: uart_a01nyub - tx_pin: - number: 17 - rx_pin: - number: 16 - baud_rate: 9600 +substitutions: + tx_pin: GPIO17 + rx_pin: GPIO16 -sensor: - - platform: a01nyub - id: a01nyub_sensor - name: a01nyub Distance - uart_id: uart_a01nyub +<<: !include common.yaml diff --git a/tests/components/a01nyub/test.esp8266.yaml b/tests/components/a01nyub/test.esp8266.yaml index 3132f77136..b516342f3b 100644 --- a/tests/components/a01nyub/test.esp8266.yaml +++ b/tests/components/a01nyub/test.esp8266.yaml @@ -1,13 +1,5 @@ -uart: - - id: uart_a01nyub - tx_pin: - number: 4 - rx_pin: - number: 5 - baud_rate: 9600 +substitutions: + tx_pin: GPIO4 + rx_pin: GPIO5 -sensor: - - platform: a01nyub - id: a01nyub_sensor - name: a01nyub Distance - uart_id: uart_a01nyub +<<: !include common.yaml diff --git a/tests/components/a01nyub/test.rp2040.yaml b/tests/components/a01nyub/test.rp2040.yaml index 3132f77136..b516342f3b 100644 --- a/tests/components/a01nyub/test.rp2040.yaml +++ b/tests/components/a01nyub/test.rp2040.yaml @@ -1,13 +1,5 @@ -uart: - - id: uart_a01nyub - tx_pin: - number: 4 - rx_pin: - number: 5 - baud_rate: 9600 +substitutions: + tx_pin: GPIO4 + rx_pin: GPIO5 -sensor: - - platform: a01nyub - id: a01nyub_sensor - name: a01nyub Distance - uart_id: uart_a01nyub +<<: !include common.yaml From d604c8ae644ee91c714c1ae887b7fcbf400a759b Mon Sep 17 00:00:00 2001 From: Keith Burzinski Date: Mon, 17 Jun 2024 02:18:04 -0500 Subject: [PATCH 12/15] [CI-api] Test fix for IDF 5+ (#6918) --- tests/components/api/common.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/components/api/common.yaml b/tests/components/api/common.yaml index 3c56811b95..e0b900f92d 100644 --- a/tests/components/api/common.yaml +++ b/tests/components/api/common.yaml @@ -50,12 +50,12 @@ api: then: - logger.log: # yamllint disable rule:line-length - format: "Bool: %s (%u), Int: %d (%u), Float: %f (%u), String: %s (%u)" + format: "Bool: %s (%u), Int: %ld (%u), Float: %f (%u), String: %s (%u)" # yamllint enable rule:line-length args: - YESNO(bool_arr[0]) - bool_arr.size() - - int_arr[0] + - (long) int_arr[0] - int_arr.size() - float_arr[0] - float_arr.size() From 41f810f8285c7f94d0f629e30828848d13cb734b Mon Sep 17 00:00:00 2001 From: Keith Burzinski Date: Mon, 17 Jun 2024 02:21:15 -0500 Subject: [PATCH 13/15] [CI-http_request] Test fix for IDF 5+ (#6919) --- tests/components/http_request/common.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/components/http_request/common.yaml b/tests/components/http_request/common.yaml index 83b334ca2d..589b7fb4b4 100644 --- a/tests/components/http_request/common.yaml +++ b/tests/components/http_request/common.yaml @@ -15,10 +15,10 @@ esphome: on_response: then: - logger.log: - format: "Response status: %d, Duration: %u ms" + format: "Response status: %d, Duration: %lu ms" args: - response->status_code - - response->duration_ms + - (long) response->duration_ms - http_request.post: url: https://esphome.io headers: From c30913ccdeebb4627a864132e8cd37c5264e88a5 Mon Sep 17 00:00:00 2001 From: Keith Burzinski Date: Mon, 17 Jun 2024 02:23:24 -0500 Subject: [PATCH 14/15] [CI-wireguard] Test file consolidation (#6920) --- tests/components/wireguard/common.yaml | 59 ++++++++++++++++++ tests/components/wireguard/test.bk72xx.yaml | 60 +----------------- .../wireguard/test.esp32-c3-idf.yaml | 61 +------------------ tests/components/wireguard/test.esp32-c3.yaml | 61 +------------------ .../components/wireguard/test.esp32-idf.yaml | 60 +----------------- tests/components/wireguard/test.esp32.yaml | 60 +----------------- tests/components/wireguard/test.esp8266.yaml | 60 +----------------- 7 files changed, 65 insertions(+), 356 deletions(-) create mode 100644 tests/components/wireguard/common.yaml diff --git a/tests/components/wireguard/common.yaml b/tests/components/wireguard/common.yaml new file mode 100644 index 0000000000..cd7ab1075e --- /dev/null +++ b/tests/components/wireguard/common.yaml @@ -0,0 +1,59 @@ +wifi: + ssid: "MySSID1" + password: "password1" + +time: + - platform: sntp + +wireguard: + address: 172.16.34.100 + netmask: 255.255.255.0 + # NEVER use the following keys for your VPN -- they are now public! + private_key: wPBMxtNYH3mChicrbpsRpZIasIdPq3yZuthn23FbGG8= + peer_public_key: Hs2JfikvYU03/Kv3YoAs1hrUIPPTEkpsZKSPUljE9yc= + peer_preshared_key: 20fjM5GRnSolGPC5SRj9ljgIUyQfruv0B0bvLl3Yt60= + peer_endpoint: wg.server.example + peer_persistent_keepalive: 25s + peer_allowed_ips: + - 172.16.34.0/24 + - 192.168.4.0/24 + +binary_sensor: + - platform: wireguard + status: + name: 'WireGuard Status' + enabled: + name: 'WireGuard Enabled' + +sensor: + - platform: wireguard + latest_handshake: + name: 'WireGuard Latest Handshake' + +text_sensor: + - platform: wireguard + address: + name: 'WireGuard Address' + +button: + - platform: template + name: 'Toggle WireGuard' + entity_category: config + on_press: + - if: + condition: wireguard.enabled + then: + - wireguard.disable: + else: + - wireguard.enable: + + - platform: template + name: 'Log WireGuard status' + entity_category: config + on_press: + - if: + condition: wireguard.peer_online + then: + - logger.log: 'wireguard remote peer is online' + else: + - logger.log: 'wireguard remote peer is offline' diff --git a/tests/components/wireguard/test.bk72xx.yaml b/tests/components/wireguard/test.bk72xx.yaml index 85325139a9..dade44d145 100644 --- a/tests/components/wireguard/test.bk72xx.yaml +++ b/tests/components/wireguard/test.bk72xx.yaml @@ -1,59 +1 @@ -wifi: - ssid: "MySSID1" - password: "password1" - -time: - - platform: sntp - -wireguard: - address: 172.16.34.100 - netmask: 255.255.255.0 - # NEVER use the following keys for your vpn, they are now public! - private_key: wPBMxtNYH3mChicrbpsRpZIasIdPq3yZuthn23FbGG8= - peer_public_key: Hs2JfikvYU03/Kv3YoAs1hrUIPPTEkpsZKSPUljE9yc= - peer_preshared_key: 20fjM5GRnSolGPC5SRj9ljgIUyQfruv0B0bvLl3Yt60= - peer_endpoint: wg.server.example - peer_persistent_keepalive: 25s - peer_allowed_ips: - - 172.16.34.0/24 - - 192.168.4.0/24 - -binary_sensor: - - platform: wireguard - status: - name: 'WireGuard Status' - enabled: - name: 'WireGuard Enabled' - -sensor: - - platform: wireguard - latest_handshake: - name: 'WireGuard Latest Handshake' - -text_sensor: - - platform: wireguard - address: - name: 'WireGuard Address' - -button: - - platform: template - name: 'Toggle WireGuard' - entity_category: config - on_press: - - if: - condition: wireguard.enabled - then: - - wireguard.disable: - else: - - wireguard.enable: - - - platform: template - name: 'Log WireGuard status' - entity_category: config - on_press: - - if: - condition: wireguard.peer_online - then: - - logger.log: 'wireguard remote peer is online' - else: - - logger.log: 'wireguard remote peer is offline' +<<: !include common.yaml diff --git a/tests/components/wireguard/test.esp32-c3-idf.yaml b/tests/components/wireguard/test.esp32-c3-idf.yaml index 37d1727842..dade44d145 100644 --- a/tests/components/wireguard/test.esp32-c3-idf.yaml +++ b/tests/components/wireguard/test.esp32-c3-idf.yaml @@ -1,60 +1 @@ -wifi: - ssid: MySSID - password: password1 - -time: - - platform: sntp - -wireguard: - id: vpn - address: 172.16.34.100 - netmask: 255.255.255.0 - # NEVER use the following keys for your vpn, they are now public! - private_key: wPBMxtNYH3mChicrbpsRpZIasIdPq3yZuthn23FbGG8= - peer_public_key: Hs2JfikvYU03/Kv3YoAs1hrUIPPTEkpsZKSPUljE9yc= - peer_preshared_key: 20fjM5GRnSolGPC5SRj9ljgIUyQfruv0B0bvLl3Yt60= - peer_endpoint: wg.server.example - peer_persistent_keepalive: 25s - peer_allowed_ips: - - 172.16.34.0/24 - - 192.168.4.0/24 - -binary_sensor: - - platform: wireguard - status: - name: 'WireGuard Status' - enabled: - name: 'WireGuard Enabled' - -sensor: - - platform: wireguard - latest_handshake: - name: 'WireGuard Latest Handshake' - -text_sensor: - - platform: wireguard - address: - name: 'WireGuard Address' - -button: - - platform: template - name: 'Toggle WireGuard' - entity_category: config - on_press: - - if: - condition: wireguard.enabled - then: - - wireguard.disable: - else: - - wireguard.enable: - - - platform: template - name: 'Log WireGuard status' - entity_category: config - on_press: - - if: - condition: wireguard.peer_online - then: - - logger.log: 'wireguard remote peer is online' - else: - - logger.log: 'wireguard remote peer is offline' +<<: !include common.yaml diff --git a/tests/components/wireguard/test.esp32-c3.yaml b/tests/components/wireguard/test.esp32-c3.yaml index 37d1727842..dade44d145 100644 --- a/tests/components/wireguard/test.esp32-c3.yaml +++ b/tests/components/wireguard/test.esp32-c3.yaml @@ -1,60 +1 @@ -wifi: - ssid: MySSID - password: password1 - -time: - - platform: sntp - -wireguard: - id: vpn - address: 172.16.34.100 - netmask: 255.255.255.0 - # NEVER use the following keys for your vpn, they are now public! - private_key: wPBMxtNYH3mChicrbpsRpZIasIdPq3yZuthn23FbGG8= - peer_public_key: Hs2JfikvYU03/Kv3YoAs1hrUIPPTEkpsZKSPUljE9yc= - peer_preshared_key: 20fjM5GRnSolGPC5SRj9ljgIUyQfruv0B0bvLl3Yt60= - peer_endpoint: wg.server.example - peer_persistent_keepalive: 25s - peer_allowed_ips: - - 172.16.34.0/24 - - 192.168.4.0/24 - -binary_sensor: - - platform: wireguard - status: - name: 'WireGuard Status' - enabled: - name: 'WireGuard Enabled' - -sensor: - - platform: wireguard - latest_handshake: - name: 'WireGuard Latest Handshake' - -text_sensor: - - platform: wireguard - address: - name: 'WireGuard Address' - -button: - - platform: template - name: 'Toggle WireGuard' - entity_category: config - on_press: - - if: - condition: wireguard.enabled - then: - - wireguard.disable: - else: - - wireguard.enable: - - - platform: template - name: 'Log WireGuard status' - entity_category: config - on_press: - - if: - condition: wireguard.peer_online - then: - - logger.log: 'wireguard remote peer is online' - else: - - logger.log: 'wireguard remote peer is offline' +<<: !include common.yaml diff --git a/tests/components/wireguard/test.esp32-idf.yaml b/tests/components/wireguard/test.esp32-idf.yaml index 9ea7f00bdb..2798f8e566 100644 --- a/tests/components/wireguard/test.esp32-idf.yaml +++ b/tests/components/wireguard/test.esp32-idf.yaml @@ -1,62 +1,4 @@ -wifi: - ssid: "MySSID1" - password: "password1" +<<: !include common.yaml network: enable_ipv6: true - -time: - - platform: sntp - -wireguard: - address: 172.16.34.100 - netmask: 255.255.255.0 - # NEVER use the following keys for your vpn, they are now public! - private_key: wPBMxtNYH3mChicrbpsRpZIasIdPq3yZuthn23FbGG8= - peer_public_key: Hs2JfikvYU03/Kv3YoAs1hrUIPPTEkpsZKSPUljE9yc= - peer_preshared_key: 20fjM5GRnSolGPC5SRj9ljgIUyQfruv0B0bvLl3Yt60= - peer_endpoint: wg.server.example - peer_persistent_keepalive: 25s - peer_allowed_ips: - - 172.16.34.0/24 - - 192.168.4.0/24 - -binary_sensor: - - platform: wireguard - status: - name: 'WireGuard Status' - enabled: - name: 'WireGuard Enabled' - -sensor: - - platform: wireguard - latest_handshake: - name: 'WireGuard Latest Handshake' - -text_sensor: - - platform: wireguard - address: - name: 'WireGuard Address' - -button: - - platform: template - name: 'Toggle WireGuard' - entity_category: config - on_press: - - if: - condition: wireguard.enabled - then: - - wireguard.disable: - else: - - wireguard.enable: - - - platform: template - name: 'Log WireGuard status' - entity_category: config - on_press: - - if: - condition: wireguard.peer_online - then: - - logger.log: 'wireguard remote peer is online' - else: - - logger.log: 'wireguard remote peer is offline' diff --git a/tests/components/wireguard/test.esp32.yaml b/tests/components/wireguard/test.esp32.yaml index 9ea7f00bdb..2798f8e566 100644 --- a/tests/components/wireguard/test.esp32.yaml +++ b/tests/components/wireguard/test.esp32.yaml @@ -1,62 +1,4 @@ -wifi: - ssid: "MySSID1" - password: "password1" +<<: !include common.yaml network: enable_ipv6: true - -time: - - platform: sntp - -wireguard: - address: 172.16.34.100 - netmask: 255.255.255.0 - # NEVER use the following keys for your vpn, they are now public! - private_key: wPBMxtNYH3mChicrbpsRpZIasIdPq3yZuthn23FbGG8= - peer_public_key: Hs2JfikvYU03/Kv3YoAs1hrUIPPTEkpsZKSPUljE9yc= - peer_preshared_key: 20fjM5GRnSolGPC5SRj9ljgIUyQfruv0B0bvLl3Yt60= - peer_endpoint: wg.server.example - peer_persistent_keepalive: 25s - peer_allowed_ips: - - 172.16.34.0/24 - - 192.168.4.0/24 - -binary_sensor: - - platform: wireguard - status: - name: 'WireGuard Status' - enabled: - name: 'WireGuard Enabled' - -sensor: - - platform: wireguard - latest_handshake: - name: 'WireGuard Latest Handshake' - -text_sensor: - - platform: wireguard - address: - name: 'WireGuard Address' - -button: - - platform: template - name: 'Toggle WireGuard' - entity_category: config - on_press: - - if: - condition: wireguard.enabled - then: - - wireguard.disable: - else: - - wireguard.enable: - - - platform: template - name: 'Log WireGuard status' - entity_category: config - on_press: - - if: - condition: wireguard.peer_online - then: - - logger.log: 'wireguard remote peer is online' - else: - - logger.log: 'wireguard remote peer is offline' diff --git a/tests/components/wireguard/test.esp8266.yaml b/tests/components/wireguard/test.esp8266.yaml index 9ea7f00bdb..2798f8e566 100644 --- a/tests/components/wireguard/test.esp8266.yaml +++ b/tests/components/wireguard/test.esp8266.yaml @@ -1,62 +1,4 @@ -wifi: - ssid: "MySSID1" - password: "password1" +<<: !include common.yaml network: enable_ipv6: true - -time: - - platform: sntp - -wireguard: - address: 172.16.34.100 - netmask: 255.255.255.0 - # NEVER use the following keys for your vpn, they are now public! - private_key: wPBMxtNYH3mChicrbpsRpZIasIdPq3yZuthn23FbGG8= - peer_public_key: Hs2JfikvYU03/Kv3YoAs1hrUIPPTEkpsZKSPUljE9yc= - peer_preshared_key: 20fjM5GRnSolGPC5SRj9ljgIUyQfruv0B0bvLl3Yt60= - peer_endpoint: wg.server.example - peer_persistent_keepalive: 25s - peer_allowed_ips: - - 172.16.34.0/24 - - 192.168.4.0/24 - -binary_sensor: - - platform: wireguard - status: - name: 'WireGuard Status' - enabled: - name: 'WireGuard Enabled' - -sensor: - - platform: wireguard - latest_handshake: - name: 'WireGuard Latest Handshake' - -text_sensor: - - platform: wireguard - address: - name: 'WireGuard Address' - -button: - - platform: template - name: 'Toggle WireGuard' - entity_category: config - on_press: - - if: - condition: wireguard.enabled - then: - - wireguard.disable: - else: - - wireguard.enable: - - - platform: template - name: 'Log WireGuard status' - entity_category: config - on_press: - - if: - condition: wireguard.peer_online - then: - - logger.log: 'wireguard remote peer is online' - else: - - logger.log: 'wireguard remote peer is offline' From a59c9b4f771f6d6a65af6caa33b0c0edae6af087 Mon Sep 17 00:00:00 2001 From: Keith Burzinski Date: Mon, 17 Jun 2024 02:30:54 -0500 Subject: [PATCH 15/15] [CI-esp32_hall] Remove IDF test (#6921) --- tests/components/esp32_hall/common.yaml | 3 --- tests/components/esp32_hall/test.esp32-idf.yaml | 1 - tests/components/esp32_hall/test.esp32.yaml | 4 +++- 3 files changed, 3 insertions(+), 5 deletions(-) delete mode 100644 tests/components/esp32_hall/common.yaml delete mode 100644 tests/components/esp32_hall/test.esp32-idf.yaml diff --git a/tests/components/esp32_hall/common.yaml b/tests/components/esp32_hall/common.yaml deleted file mode 100644 index f8429f5aa0..0000000000 --- a/tests/components/esp32_hall/common.yaml +++ /dev/null @@ -1,3 +0,0 @@ -sensor: - - platform: esp32_hall - name: ESP32 Hall Sensor diff --git a/tests/components/esp32_hall/test.esp32-idf.yaml b/tests/components/esp32_hall/test.esp32-idf.yaml deleted file mode 100644 index dade44d145..0000000000 --- a/tests/components/esp32_hall/test.esp32-idf.yaml +++ /dev/null @@ -1 +0,0 @@ -<<: !include common.yaml diff --git a/tests/components/esp32_hall/test.esp32.yaml b/tests/components/esp32_hall/test.esp32.yaml index dade44d145..f8429f5aa0 100644 --- a/tests/components/esp32_hall/test.esp32.yaml +++ b/tests/components/esp32_hall/test.esp32.yaml @@ -1 +1,3 @@ -<<: !include common.yaml +sensor: + - platform: esp32_hall + name: ESP32 Hall Sensor