diff --git a/tests/components/max31855/common.yaml b/tests/components/max31855/common.yaml
new file mode 100644
index 0000000000..7136c597d5
--- /dev/null
+++ b/tests/components/max31855/common.yaml
@@ -0,0 +1,13 @@
+spi:
+  - id: spi_max31855
+    clk_pin: ${clk_pin}
+    mosi_pin: ${mosi_pin}
+    miso_pin: ${miso_pin}
+
+sensor:
+  - platform: max31855
+    name: MAX31855 Temperature
+    cs_pin: ${cs_pin}
+    update_interval: 15s
+    reference_temperature:
+      name: MAX31855 Internal Temperature
diff --git a/tests/components/max31855/test.esp32-ard.yaml b/tests/components/max31855/test.esp32-ard.yaml
index 25fee986d2..54e027a614 100644
--- a/tests/components/max31855/test.esp32-ard.yaml
+++ b/tests/components/max31855/test.esp32-ard.yaml
@@ -1,13 +1,7 @@
-spi:
-  - id: spi_max31855
-    clk_pin: 16
-    mosi_pin: 17
-    miso_pin: 15
+substitutions:
+  clk_pin: GPIO16
+  mosi_pin: GPIO17
+  miso_pin: GPIO15
+  cs_pin: GPIO5
 
-sensor:
-  - platform: max31855
-    name: MAX31855 Temperature
-    cs_pin: 12
-    update_interval: 15s
-    reference_temperature:
-      name: MAX31855 Internal Temperature
+<<: !include common.yaml
diff --git a/tests/components/max31855/test.esp32-c3-ard.yaml b/tests/components/max31855/test.esp32-c3-ard.yaml
index e7c8f3f824..2415ba5dc6 100644
--- a/tests/components/max31855/test.esp32-c3-ard.yaml
+++ b/tests/components/max31855/test.esp32-c3-ard.yaml
@@ -1,13 +1,7 @@
-spi:
-  - id: spi_max31855
-    clk_pin: 6
-    mosi_pin: 7
-    miso_pin: 5
+substitutions:
+  clk_pin: GPIO6
+  mosi_pin: GPIO7
+  miso_pin: GPIO5
+  cs_pin: GPIO8
 
-sensor:
-  - platform: max31855
-    name: MAX31855 Temperature
-    cs_pin: 8
-    update_interval: 15s
-    reference_temperature:
-      name: MAX31855 Internal Temperature
+<<: !include common.yaml
diff --git a/tests/components/max31855/test.esp32-c3-idf.yaml b/tests/components/max31855/test.esp32-c3-idf.yaml
index e7c8f3f824..2415ba5dc6 100644
--- a/tests/components/max31855/test.esp32-c3-idf.yaml
+++ b/tests/components/max31855/test.esp32-c3-idf.yaml
@@ -1,13 +1,7 @@
-spi:
-  - id: spi_max31855
-    clk_pin: 6
-    mosi_pin: 7
-    miso_pin: 5
+substitutions:
+  clk_pin: GPIO6
+  mosi_pin: GPIO7
+  miso_pin: GPIO5
+  cs_pin: GPIO8
 
-sensor:
-  - platform: max31855
-    name: MAX31855 Temperature
-    cs_pin: 8
-    update_interval: 15s
-    reference_temperature:
-      name: MAX31855 Internal Temperature
+<<: !include common.yaml
diff --git a/tests/components/max31855/test.esp32-idf.yaml b/tests/components/max31855/test.esp32-idf.yaml
index 25fee986d2..54e027a614 100644
--- a/tests/components/max31855/test.esp32-idf.yaml
+++ b/tests/components/max31855/test.esp32-idf.yaml
@@ -1,13 +1,7 @@
-spi:
-  - id: spi_max31855
-    clk_pin: 16
-    mosi_pin: 17
-    miso_pin: 15
+substitutions:
+  clk_pin: GPIO16
+  mosi_pin: GPIO17
+  miso_pin: GPIO15
+  cs_pin: GPIO5
 
-sensor:
-  - platform: max31855
-    name: MAX31855 Temperature
-    cs_pin: 12
-    update_interval: 15s
-    reference_temperature:
-      name: MAX31855 Internal Temperature
+<<: !include common.yaml
diff --git a/tests/components/max31855/test.esp8266-ard.yaml b/tests/components/max31855/test.esp8266-ard.yaml
index 7e02d41fce..dbd158d030 100644
--- a/tests/components/max31855/test.esp8266-ard.yaml
+++ b/tests/components/max31855/test.esp8266-ard.yaml
@@ -1,13 +1,7 @@
-spi:
-  - id: spi_max31855
-    clk_pin: 14
-    mosi_pin: 13
-    miso_pin: 12
+substitutions:
+  clk_pin: GPIO14
+  mosi_pin: GPIO13
+  miso_pin: GPIO12
+  cs_pin: GPIO15
 
-sensor:
-  - platform: max31855
-    name: MAX31855 Temperature
-    cs_pin: 15
-    update_interval: 15s
-    reference_temperature:
-      name: MAX31855 Internal Temperature
+<<: !include common.yaml
diff --git a/tests/components/max31855/test.rp2040-ard.yaml b/tests/components/max31855/test.rp2040-ard.yaml
index 379d4d33d6..f6c3f1eeca 100644
--- a/tests/components/max31855/test.rp2040-ard.yaml
+++ b/tests/components/max31855/test.rp2040-ard.yaml
@@ -1,13 +1,7 @@
-spi:
-  - id: spi_max31855
-    clk_pin: 2
-    mosi_pin: 3
-    miso_pin: 4
+substitutions:
+  clk_pin: GPIO2
+  mosi_pin: GPIO3
+  miso_pin: GPIO4
+  cs_pin: GPIO5
 
-sensor:
-  - platform: max31855
-    name: MAX31855 Temperature
-    cs_pin: 6
-    update_interval: 15s
-    reference_temperature:
-      name: MAX31855 Internal Temperature
+<<: !include common.yaml
diff --git a/tests/components/max31856/common.yaml b/tests/components/max31856/common.yaml
new file mode 100644
index 0000000000..4f7c3ad408
--- /dev/null
+++ b/tests/components/max31856/common.yaml
@@ -0,0 +1,13 @@
+spi:
+  - id: spi_max31856
+    clk_pin: ${clk_pin}
+    mosi_pin: ${mosi_pin}
+    miso_pin: ${miso_pin}
+
+sensor:
+  - platform: max31856
+    name: MAX31856 Temperature
+    cs_pin: ${cs_pin}
+    update_interval: 15s
+    mains_filter: 50Hz
+    thermocouple_type: N
diff --git a/tests/components/max31856/test.esp32-ard.yaml b/tests/components/max31856/test.esp32-ard.yaml
index 9a4da6b2a2..54e027a614 100644
--- a/tests/components/max31856/test.esp32-ard.yaml
+++ b/tests/components/max31856/test.esp32-ard.yaml
@@ -1,13 +1,7 @@
-spi:
-  - id: spi_max31856
-    clk_pin: 16
-    mosi_pin: 17
-    miso_pin: 15
+substitutions:
+  clk_pin: GPIO16
+  mosi_pin: GPIO17
+  miso_pin: GPIO15
+  cs_pin: GPIO5
 
-sensor:
-  - platform: max31856
-    name: MAX31856 Temperature
-    cs_pin: 12
-    update_interval: 15s
-    mains_filter: 50Hz
-    thermocouple_type: N
+<<: !include common.yaml
diff --git a/tests/components/max31856/test.esp32-c3-ard.yaml b/tests/components/max31856/test.esp32-c3-ard.yaml
index 71bbfffb7b..2415ba5dc6 100644
--- a/tests/components/max31856/test.esp32-c3-ard.yaml
+++ b/tests/components/max31856/test.esp32-c3-ard.yaml
@@ -1,14 +1,7 @@
-spi:
-  - id: spi_max31856
-    clk_pin: 6
-    mosi_pin: 7
-    miso_pin: 5
-
-sensor:
-  - platform: max31856
-    name: MAX31856 Temperature
-    cs_pin: 8
-    update_interval: 15s
-    mains_filter: 50Hz
-    thermocouple_type: N
+substitutions:
+  clk_pin: GPIO6
+  mosi_pin: GPIO7
+  miso_pin: GPIO5
+  cs_pin: GPIO8
 
+<<: !include common.yaml
diff --git a/tests/components/max31856/test.esp32-c3-idf.yaml b/tests/components/max31856/test.esp32-c3-idf.yaml
index 71bbfffb7b..2415ba5dc6 100644
--- a/tests/components/max31856/test.esp32-c3-idf.yaml
+++ b/tests/components/max31856/test.esp32-c3-idf.yaml
@@ -1,14 +1,7 @@
-spi:
-  - id: spi_max31856
-    clk_pin: 6
-    mosi_pin: 7
-    miso_pin: 5
-
-sensor:
-  - platform: max31856
-    name: MAX31856 Temperature
-    cs_pin: 8
-    update_interval: 15s
-    mains_filter: 50Hz
-    thermocouple_type: N
+substitutions:
+  clk_pin: GPIO6
+  mosi_pin: GPIO7
+  miso_pin: GPIO5
+  cs_pin: GPIO8
 
+<<: !include common.yaml
diff --git a/tests/components/max31856/test.esp32-idf.yaml b/tests/components/max31856/test.esp32-idf.yaml
index 9a4da6b2a2..54e027a614 100644
--- a/tests/components/max31856/test.esp32-idf.yaml
+++ b/tests/components/max31856/test.esp32-idf.yaml
@@ -1,13 +1,7 @@
-spi:
-  - id: spi_max31856
-    clk_pin: 16
-    mosi_pin: 17
-    miso_pin: 15
+substitutions:
+  clk_pin: GPIO16
+  mosi_pin: GPIO17
+  miso_pin: GPIO15
+  cs_pin: GPIO5
 
-sensor:
-  - platform: max31856
-    name: MAX31856 Temperature
-    cs_pin: 12
-    update_interval: 15s
-    mains_filter: 50Hz
-    thermocouple_type: N
+<<: !include common.yaml
diff --git a/tests/components/max31856/test.esp8266-ard.yaml b/tests/components/max31856/test.esp8266-ard.yaml
index b9c42542fd..dbd158d030 100644
--- a/tests/components/max31856/test.esp8266-ard.yaml
+++ b/tests/components/max31856/test.esp8266-ard.yaml
@@ -1,14 +1,7 @@
-spi:
-  - id: spi_max31856
-    clk_pin: 14
-    mosi_pin: 13
-    miso_pin: 12
-
-sensor:
-  - platform: max31856
-    name: MAX31856 Temperature
-    cs_pin: 15
-    update_interval: 15s
-    mains_filter: 50Hz
-    thermocouple_type: N
+substitutions:
+  clk_pin: GPIO14
+  mosi_pin: GPIO13
+  miso_pin: GPIO12
+  cs_pin: GPIO15
 
+<<: !include common.yaml
diff --git a/tests/components/max31856/test.rp2040-ard.yaml b/tests/components/max31856/test.rp2040-ard.yaml
index 8607eb18cf..f6c3f1eeca 100644
--- a/tests/components/max31856/test.rp2040-ard.yaml
+++ b/tests/components/max31856/test.rp2040-ard.yaml
@@ -1,14 +1,7 @@
-spi:
-  - id: spi_max31856
-    clk_pin: 2
-    mosi_pin: 3
-    miso_pin: 4
-
-sensor:
-  - platform: max31856
-    name: MAX31856 Temperature
-    cs_pin: 6
-    update_interval: 15s
-    mains_filter: 50Hz
-    thermocouple_type: N
+substitutions:
+  clk_pin: GPIO2
+  mosi_pin: GPIO3
+  miso_pin: GPIO4
+  cs_pin: GPIO5
 
+<<: !include common.yaml
diff --git a/tests/components/max31865/common.yaml b/tests/components/max31865/common.yaml
new file mode 100644
index 0000000000..5bb7bda5aa
--- /dev/null
+++ b/tests/components/max31865/common.yaml
@@ -0,0 +1,13 @@
+spi:
+  - id: spi_max31865
+    clk_pin: ${clk_pin}
+    mosi_pin: ${mosi_pin}
+    miso_pin: ${miso_pin}
+
+sensor:
+  - platform: max31865
+    name: MAX31865 Temperature
+    cs_pin: ${cs_pin}
+    update_interval: 15s
+    reference_resistance: 430 Ω
+    rtd_nominal_resistance: 100 Ω
diff --git a/tests/components/max31865/test.esp32-ard.yaml b/tests/components/max31865/test.esp32-ard.yaml
index 8326a578ee..54e027a614 100644
--- a/tests/components/max31865/test.esp32-ard.yaml
+++ b/tests/components/max31865/test.esp32-ard.yaml
@@ -1,13 +1,7 @@
-spi:
-  - id: spi_max31865
-    clk_pin: 16
-    mosi_pin: 17
-    miso_pin: 15
+substitutions:
+  clk_pin: GPIO16
+  mosi_pin: GPIO17
+  miso_pin: GPIO15
+  cs_pin: GPIO5
 
-sensor:
-  - platform: max31865
-    name: MAX31865 Temperature
-    cs_pin: 12
-    update_interval: 15s
-    reference_resistance: 430 Ω
-    rtd_nominal_resistance: 100 Ω
+<<: !include common.yaml
diff --git a/tests/components/max31865/test.esp32-c3-ard.yaml b/tests/components/max31865/test.esp32-c3-ard.yaml
index 45de22331e..2415ba5dc6 100644
--- a/tests/components/max31865/test.esp32-c3-ard.yaml
+++ b/tests/components/max31865/test.esp32-c3-ard.yaml
@@ -1,13 +1,7 @@
-spi:
-  - id: spi_max31865
-    clk_pin: 6
-    mosi_pin: 7
-    miso_pin: 5
+substitutions:
+  clk_pin: GPIO6
+  mosi_pin: GPIO7
+  miso_pin: GPIO5
+  cs_pin: GPIO8
 
-sensor:
-  - platform: max31865
-    name: MAX31865 Temperature
-    cs_pin: 8
-    update_interval: 15s
-    reference_resistance: 430 Ω
-    rtd_nominal_resistance: 100 Ω
+<<: !include common.yaml
diff --git a/tests/components/max31865/test.esp32-c3-idf.yaml b/tests/components/max31865/test.esp32-c3-idf.yaml
index 45de22331e..2415ba5dc6 100644
--- a/tests/components/max31865/test.esp32-c3-idf.yaml
+++ b/tests/components/max31865/test.esp32-c3-idf.yaml
@@ -1,13 +1,7 @@
-spi:
-  - id: spi_max31865
-    clk_pin: 6
-    mosi_pin: 7
-    miso_pin: 5
+substitutions:
+  clk_pin: GPIO6
+  mosi_pin: GPIO7
+  miso_pin: GPIO5
+  cs_pin: GPIO8
 
-sensor:
-  - platform: max31865
-    name: MAX31865 Temperature
-    cs_pin: 8
-    update_interval: 15s
-    reference_resistance: 430 Ω
-    rtd_nominal_resistance: 100 Ω
+<<: !include common.yaml
diff --git a/tests/components/max31865/test.esp32-idf.yaml b/tests/components/max31865/test.esp32-idf.yaml
index 8326a578ee..54e027a614 100644
--- a/tests/components/max31865/test.esp32-idf.yaml
+++ b/tests/components/max31865/test.esp32-idf.yaml
@@ -1,13 +1,7 @@
-spi:
-  - id: spi_max31865
-    clk_pin: 16
-    mosi_pin: 17
-    miso_pin: 15
+substitutions:
+  clk_pin: GPIO16
+  mosi_pin: GPIO17
+  miso_pin: GPIO15
+  cs_pin: GPIO5
 
-sensor:
-  - platform: max31865
-    name: MAX31865 Temperature
-    cs_pin: 12
-    update_interval: 15s
-    reference_resistance: 430 Ω
-    rtd_nominal_resistance: 100 Ω
+<<: !include common.yaml
diff --git a/tests/components/max31865/test.esp8266-ard.yaml b/tests/components/max31865/test.esp8266-ard.yaml
index 4828019acc..dbd158d030 100644
--- a/tests/components/max31865/test.esp8266-ard.yaml
+++ b/tests/components/max31865/test.esp8266-ard.yaml
@@ -1,13 +1,7 @@
-spi:
-  - id: spi_max31865
-    clk_pin: 14
-    mosi_pin: 13
-    miso_pin: 12
+substitutions:
+  clk_pin: GPIO14
+  mosi_pin: GPIO13
+  miso_pin: GPIO12
+  cs_pin: GPIO15
 
-sensor:
-  - platform: max31865
-    name: MAX31865 Temperature
-    cs_pin: 15
-    update_interval: 15s
-    reference_resistance: 430 Ω
-    rtd_nominal_resistance: 100 Ω
+<<: !include common.yaml
diff --git a/tests/components/max31865/test.rp2040-ard.yaml b/tests/components/max31865/test.rp2040-ard.yaml
index 5af64b41ad..f6c3f1eeca 100644
--- a/tests/components/max31865/test.rp2040-ard.yaml
+++ b/tests/components/max31865/test.rp2040-ard.yaml
@@ -1,13 +1,7 @@
-spi:
-  - id: spi_max31865
-    clk_pin: 2
-    mosi_pin: 3
-    miso_pin: 4
+substitutions:
+  clk_pin: GPIO2
+  mosi_pin: GPIO3
+  miso_pin: GPIO4
+  cs_pin: GPIO5
 
-sensor:
-  - platform: max31865
-    name: MAX31865 Temperature
-    cs_pin: 6
-    update_interval: 15s
-    reference_resistance: 430 Ω
-    rtd_nominal_resistance: 100 Ω
+<<: !include common.yaml
diff --git a/tests/components/max44009/common.yaml b/tests/components/max44009/common.yaml
new file mode 100644
index 0000000000..ef51740895
--- /dev/null
+++ b/tests/components/max44009/common.yaml
@@ -0,0 +1,12 @@
+i2c:
+  - id: i2c_max44009
+    scl: ${scl_pin}
+    sda: ${sda_pin}
+
+sensor:
+  - platform: max44009
+    name: MAX44009 Brightness
+    internal: true
+    mode: low_power
+    address: 0x4A
+    update_interval: 30s
diff --git a/tests/components/max44009/test.esp32-ard.yaml b/tests/components/max44009/test.esp32-ard.yaml
index 56eecebc4a..63c3bd6afd 100644
--- a/tests/components/max44009/test.esp32-ard.yaml
+++ b/tests/components/max44009/test.esp32-ard.yaml
@@ -1,12 +1,5 @@
-i2c:
-  - id: i2c_max44009
-    scl: 16
-    sda: 17
+substitutions:
+  scl_pin: GPIO16
+  sda_pin: GPIO17
 
-sensor:
-  - platform: max44009
-    name: MAX44009 Brightness
-    internal: true
-    mode: low_power
-    address: 0x4A
-    update_interval: 30s
+<<: !include common.yaml
diff --git a/tests/components/max44009/test.esp32-c3-ard.yaml b/tests/components/max44009/test.esp32-c3-ard.yaml
index 593d4bd48c..ee2c29ca4e 100644
--- a/tests/components/max44009/test.esp32-c3-ard.yaml
+++ b/tests/components/max44009/test.esp32-c3-ard.yaml
@@ -1,12 +1,5 @@
-i2c:
-  - id: i2c_max44009
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: max44009
-    name: MAX44009 Brightness
-    internal: true
-    mode: low_power
-    address: 0x4A
-    update_interval: 30s
+<<: !include common.yaml
diff --git a/tests/components/max44009/test.esp32-c3-idf.yaml b/tests/components/max44009/test.esp32-c3-idf.yaml
index 593d4bd48c..ee2c29ca4e 100644
--- a/tests/components/max44009/test.esp32-c3-idf.yaml
+++ b/tests/components/max44009/test.esp32-c3-idf.yaml
@@ -1,12 +1,5 @@
-i2c:
-  - id: i2c_max44009
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: max44009
-    name: MAX44009 Brightness
-    internal: true
-    mode: low_power
-    address: 0x4A
-    update_interval: 30s
+<<: !include common.yaml
diff --git a/tests/components/max44009/test.esp32-idf.yaml b/tests/components/max44009/test.esp32-idf.yaml
index 56eecebc4a..63c3bd6afd 100644
--- a/tests/components/max44009/test.esp32-idf.yaml
+++ b/tests/components/max44009/test.esp32-idf.yaml
@@ -1,12 +1,5 @@
-i2c:
-  - id: i2c_max44009
-    scl: 16
-    sda: 17
+substitutions:
+  scl_pin: GPIO16
+  sda_pin: GPIO17
 
-sensor:
-  - platform: max44009
-    name: MAX44009 Brightness
-    internal: true
-    mode: low_power
-    address: 0x4A
-    update_interval: 30s
+<<: !include common.yaml
diff --git a/tests/components/max44009/test.esp8266-ard.yaml b/tests/components/max44009/test.esp8266-ard.yaml
index 593d4bd48c..ee2c29ca4e 100644
--- a/tests/components/max44009/test.esp8266-ard.yaml
+++ b/tests/components/max44009/test.esp8266-ard.yaml
@@ -1,12 +1,5 @@
-i2c:
-  - id: i2c_max44009
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: max44009
-    name: MAX44009 Brightness
-    internal: true
-    mode: low_power
-    address: 0x4A
-    update_interval: 30s
+<<: !include common.yaml
diff --git a/tests/components/max44009/test.rp2040-ard.yaml b/tests/components/max44009/test.rp2040-ard.yaml
index 593d4bd48c..ee2c29ca4e 100644
--- a/tests/components/max44009/test.rp2040-ard.yaml
+++ b/tests/components/max44009/test.rp2040-ard.yaml
@@ -1,12 +1,5 @@
-i2c:
-  - id: i2c_max44009
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: max44009
-    name: MAX44009 Brightness
-    internal: true
-    mode: low_power
-    address: 0x4A
-    update_interval: 30s
+<<: !include common.yaml
diff --git a/tests/components/max6675/common.yaml b/tests/components/max6675/common.yaml
new file mode 100644
index 0000000000..5b4e04b317
--- /dev/null
+++ b/tests/components/max6675/common.yaml
@@ -0,0 +1,11 @@
+spi:
+  - id: spi_max6675
+    clk_pin: ${clk_pin}
+    mosi_pin: ${mosi_pin}
+    miso_pin: ${miso_pin}
+
+sensor:
+  - platform: max6675
+    name: Temperature
+    cs_pin: ${cs_pin}
+    update_interval: 15s
diff --git a/tests/components/max6675/test.esp32-ard.yaml b/tests/components/max6675/test.esp32-ard.yaml
index 9771bf9d5f..54e027a614 100644
--- a/tests/components/max6675/test.esp32-ard.yaml
+++ b/tests/components/max6675/test.esp32-ard.yaml
@@ -1,11 +1,7 @@
-spi:
-  - id: spi_max6675
-    clk_pin: 16
-    mosi_pin: 17
-    miso_pin: 15
+substitutions:
+  clk_pin: GPIO16
+  mosi_pin: GPIO17
+  miso_pin: GPIO15
+  cs_pin: GPIO5
 
-sensor:
-  - platform: max6675
-    name: Temperature
-    cs_pin: 12
-    update_interval: 15s
+<<: !include common.yaml
diff --git a/tests/components/max6675/test.esp32-c3-ard.yaml b/tests/components/max6675/test.esp32-c3-ard.yaml
index 2f05102ca1..2415ba5dc6 100644
--- a/tests/components/max6675/test.esp32-c3-ard.yaml
+++ b/tests/components/max6675/test.esp32-c3-ard.yaml
@@ -1,11 +1,7 @@
-spi:
-  - id: spi_max6675
-    clk_pin: 6
-    mosi_pin: 7
-    miso_pin: 5
+substitutions:
+  clk_pin: GPIO6
+  mosi_pin: GPIO7
+  miso_pin: GPIO5
+  cs_pin: GPIO8
 
-sensor:
-  - platform: max6675
-    name: Temperature
-    cs_pin: 8
-    update_interval: 15s
+<<: !include common.yaml
diff --git a/tests/components/max6675/test.esp32-c3-idf.yaml b/tests/components/max6675/test.esp32-c3-idf.yaml
index 2f05102ca1..2415ba5dc6 100644
--- a/tests/components/max6675/test.esp32-c3-idf.yaml
+++ b/tests/components/max6675/test.esp32-c3-idf.yaml
@@ -1,11 +1,7 @@
-spi:
-  - id: spi_max6675
-    clk_pin: 6
-    mosi_pin: 7
-    miso_pin: 5
+substitutions:
+  clk_pin: GPIO6
+  mosi_pin: GPIO7
+  miso_pin: GPIO5
+  cs_pin: GPIO8
 
-sensor:
-  - platform: max6675
-    name: Temperature
-    cs_pin: 8
-    update_interval: 15s
+<<: !include common.yaml
diff --git a/tests/components/max6675/test.esp32-idf.yaml b/tests/components/max6675/test.esp32-idf.yaml
index 9771bf9d5f..54e027a614 100644
--- a/tests/components/max6675/test.esp32-idf.yaml
+++ b/tests/components/max6675/test.esp32-idf.yaml
@@ -1,11 +1,7 @@
-spi:
-  - id: spi_max6675
-    clk_pin: 16
-    mosi_pin: 17
-    miso_pin: 15
+substitutions:
+  clk_pin: GPIO16
+  mosi_pin: GPIO17
+  miso_pin: GPIO15
+  cs_pin: GPIO5
 
-sensor:
-  - platform: max6675
-    name: Temperature
-    cs_pin: 12
-    update_interval: 15s
+<<: !include common.yaml
diff --git a/tests/components/max6675/test.esp8266-ard.yaml b/tests/components/max6675/test.esp8266-ard.yaml
index f67e9e04a8..dbd158d030 100644
--- a/tests/components/max6675/test.esp8266-ard.yaml
+++ b/tests/components/max6675/test.esp8266-ard.yaml
@@ -1,11 +1,7 @@
-spi:
-  - id: spi_max6675
-    clk_pin: 14
-    mosi_pin: 13
-    miso_pin: 12
+substitutions:
+  clk_pin: GPIO14
+  mosi_pin: GPIO13
+  miso_pin: GPIO12
+  cs_pin: GPIO15
 
-sensor:
-  - platform: max6675
-    name: Temperature
-    cs_pin: 15
-    update_interval: 15s
+<<: !include common.yaml
diff --git a/tests/components/max6675/test.rp2040-ard.yaml b/tests/components/max6675/test.rp2040-ard.yaml
index 89c0932f94..f6c3f1eeca 100644
--- a/tests/components/max6675/test.rp2040-ard.yaml
+++ b/tests/components/max6675/test.rp2040-ard.yaml
@@ -1,11 +1,7 @@
-spi:
-  - id: spi_max6675
-    clk_pin: 2
-    mosi_pin: 3
-    miso_pin: 4
+substitutions:
+  clk_pin: GPIO2
+  mosi_pin: GPIO3
+  miso_pin: GPIO4
+  cs_pin: GPIO5
 
-sensor:
-  - platform: max6675
-    name: Temperature
-    cs_pin: 6
-    update_interval: 15s
+<<: !include common.yaml
diff --git a/tests/components/max6956/common.yaml b/tests/components/max6956/common.yaml
new file mode 100644
index 0000000000..e44e3464f8
--- /dev/null
+++ b/tests/components/max6956/common.yaml
@@ -0,0 +1,19 @@
+i2c:
+  - id: i2c_max6956
+    scl: ${scl_pin}
+    sda: ${sda_pin}
+
+max6956:
+  - id: max6956_1
+    address: 0x40
+
+binary_sensor:
+  - platform: gpio
+    name: Max Input Pin
+    pin:
+      max6956: max6956_1
+      number: 4
+      mode:
+        input: true
+        pullup: true
+      inverted: false
diff --git a/tests/components/max6956/test.esp32-ard.yaml b/tests/components/max6956/test.esp32-ard.yaml
index abd1404634..63c3bd6afd 100644
--- a/tests/components/max6956/test.esp32-ard.yaml
+++ b/tests/components/max6956/test.esp32-ard.yaml
@@ -1,19 +1,5 @@
-i2c:
-  - id: i2c_max6956
-    scl: 16
-    sda: 17
+substitutions:
+  scl_pin: GPIO16
+  sda_pin: GPIO17
 
-max6956:
-  - id: max6956_1
-    address: 0x40
-
-binary_sensor:
-  - platform: gpio
-    name: Max Input Pin 4
-    pin:
-      max6956: max6956_1
-      number: 4
-      mode:
-        input: true
-        pullup: true
-      inverted: false
+<<: !include common.yaml
diff --git a/tests/components/max6956/test.esp32-c3-ard.yaml b/tests/components/max6956/test.esp32-c3-ard.yaml
index 690941784c..ee2c29ca4e 100644
--- a/tests/components/max6956/test.esp32-c3-ard.yaml
+++ b/tests/components/max6956/test.esp32-c3-ard.yaml
@@ -1,19 +1,5 @@
-i2c:
-  - id: i2c_max6956
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-max6956:
-  - id: max6956_1
-    address: 0x40
-
-binary_sensor:
-  - platform: gpio
-    name: Max Input Pin 4
-    pin:
-      max6956: max6956_1
-      number: 4
-      mode:
-        input: true
-        pullup: true
-      inverted: false
+<<: !include common.yaml
diff --git a/tests/components/max6956/test.esp32-c3-idf.yaml b/tests/components/max6956/test.esp32-c3-idf.yaml
index 690941784c..ee2c29ca4e 100644
--- a/tests/components/max6956/test.esp32-c3-idf.yaml
+++ b/tests/components/max6956/test.esp32-c3-idf.yaml
@@ -1,19 +1,5 @@
-i2c:
-  - id: i2c_max6956
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-max6956:
-  - id: max6956_1
-    address: 0x40
-
-binary_sensor:
-  - platform: gpio
-    name: Max Input Pin 4
-    pin:
-      max6956: max6956_1
-      number: 4
-      mode:
-        input: true
-        pullup: true
-      inverted: false
+<<: !include common.yaml
diff --git a/tests/components/max6956/test.esp32-idf.yaml b/tests/components/max6956/test.esp32-idf.yaml
index abd1404634..63c3bd6afd 100644
--- a/tests/components/max6956/test.esp32-idf.yaml
+++ b/tests/components/max6956/test.esp32-idf.yaml
@@ -1,19 +1,5 @@
-i2c:
-  - id: i2c_max6956
-    scl: 16
-    sda: 17
+substitutions:
+  scl_pin: GPIO16
+  sda_pin: GPIO17
 
-max6956:
-  - id: max6956_1
-    address: 0x40
-
-binary_sensor:
-  - platform: gpio
-    name: Max Input Pin 4
-    pin:
-      max6956: max6956_1
-      number: 4
-      mode:
-        input: true
-        pullup: true
-      inverted: false
+<<: !include common.yaml
diff --git a/tests/components/max6956/test.esp8266-ard.yaml b/tests/components/max6956/test.esp8266-ard.yaml
index 690941784c..ee2c29ca4e 100644
--- a/tests/components/max6956/test.esp8266-ard.yaml
+++ b/tests/components/max6956/test.esp8266-ard.yaml
@@ -1,19 +1,5 @@
-i2c:
-  - id: i2c_max6956
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-max6956:
-  - id: max6956_1
-    address: 0x40
-
-binary_sensor:
-  - platform: gpio
-    name: Max Input Pin 4
-    pin:
-      max6956: max6956_1
-      number: 4
-      mode:
-        input: true
-        pullup: true
-      inverted: false
+<<: !include common.yaml
diff --git a/tests/components/max6956/test.rp2040-ard.yaml b/tests/components/max6956/test.rp2040-ard.yaml
index 690941784c..ee2c29ca4e 100644
--- a/tests/components/max6956/test.rp2040-ard.yaml
+++ b/tests/components/max6956/test.rp2040-ard.yaml
@@ -1,19 +1,5 @@
-i2c:
-  - id: i2c_max6956
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-max6956:
-  - id: max6956_1
-    address: 0x40
-
-binary_sensor:
-  - platform: gpio
-    name: Max Input Pin 4
-    pin:
-      max6956: max6956_1
-      number: 4
-      mode:
-        input: true
-        pullup: true
-      inverted: false
+<<: !include common.yaml
diff --git a/tests/components/max7219/common.yaml b/tests/components/max7219/common.yaml
new file mode 100644
index 0000000000..0060db191e
--- /dev/null
+++ b/tests/components/max7219/common.yaml
@@ -0,0 +1,12 @@
+spi:
+  - id: spi_max6675
+    clk_pin: ${clk_pin}
+    mosi_pin: ${mosi_pin}
+    miso_pin: ${miso_pin}
+
+display:
+  - platform: max7219
+    cs_pin: ${cs_pin}
+    num_chips: 1
+    lambda: |-
+      it.print("01234567");
diff --git a/tests/components/max7219/test.esp32-ard.yaml b/tests/components/max7219/test.esp32-ard.yaml
index 2985345a48..54e027a614 100644
--- a/tests/components/max7219/test.esp32-ard.yaml
+++ b/tests/components/max7219/test.esp32-ard.yaml
@@ -1,12 +1,7 @@
-spi:
-  - id: spi_max6675
-    clk_pin: 16
-    mosi_pin: 17
-    miso_pin: 15
+substitutions:
+  clk_pin: GPIO16
+  mosi_pin: GPIO17
+  miso_pin: GPIO15
+  cs_pin: GPIO5
 
-display:
-  - platform: max7219
-    cs_pin: 12
-    num_chips: 1
-    lambda: |-
-      it.print("01234567");
+<<: !include common.yaml
diff --git a/tests/components/max7219/test.esp32-c3-ard.yaml b/tests/components/max7219/test.esp32-c3-ard.yaml
index fa1ac15f33..2415ba5dc6 100644
--- a/tests/components/max7219/test.esp32-c3-ard.yaml
+++ b/tests/components/max7219/test.esp32-c3-ard.yaml
@@ -1,12 +1,7 @@
-spi:
-  - id: spi_max7219
-    clk_pin: 6
-    mosi_pin: 7
-    miso_pin: 5
+substitutions:
+  clk_pin: GPIO6
+  mosi_pin: GPIO7
+  miso_pin: GPIO5
+  cs_pin: GPIO8
 
-display:
-  - platform: max7219
-    cs_pin: 8
-    num_chips: 1
-    lambda: |-
-      it.print("01234567");
+<<: !include common.yaml
diff --git a/tests/components/max7219/test.esp32-c3-idf.yaml b/tests/components/max7219/test.esp32-c3-idf.yaml
index fa1ac15f33..2415ba5dc6 100644
--- a/tests/components/max7219/test.esp32-c3-idf.yaml
+++ b/tests/components/max7219/test.esp32-c3-idf.yaml
@@ -1,12 +1,7 @@
-spi:
-  - id: spi_max7219
-    clk_pin: 6
-    mosi_pin: 7
-    miso_pin: 5
+substitutions:
+  clk_pin: GPIO6
+  mosi_pin: GPIO7
+  miso_pin: GPIO5
+  cs_pin: GPIO8
 
-display:
-  - platform: max7219
-    cs_pin: 8
-    num_chips: 1
-    lambda: |-
-      it.print("01234567");
+<<: !include common.yaml
diff --git a/tests/components/max7219/test.esp32-idf.yaml b/tests/components/max7219/test.esp32-idf.yaml
index 2985345a48..54e027a614 100644
--- a/tests/components/max7219/test.esp32-idf.yaml
+++ b/tests/components/max7219/test.esp32-idf.yaml
@@ -1,12 +1,7 @@
-spi:
-  - id: spi_max6675
-    clk_pin: 16
-    mosi_pin: 17
-    miso_pin: 15
+substitutions:
+  clk_pin: GPIO16
+  mosi_pin: GPIO17
+  miso_pin: GPIO15
+  cs_pin: GPIO5
 
-display:
-  - platform: max7219
-    cs_pin: 12
-    num_chips: 1
-    lambda: |-
-      it.print("01234567");
+<<: !include common.yaml
diff --git a/tests/components/max7219/test.esp8266-ard.yaml b/tests/components/max7219/test.esp8266-ard.yaml
index a8c280daff..dbd158d030 100644
--- a/tests/components/max7219/test.esp8266-ard.yaml
+++ b/tests/components/max7219/test.esp8266-ard.yaml
@@ -1,12 +1,7 @@
-spi:
-  - id: spi_max6675
-    clk_pin: 14
-    mosi_pin: 13
-    miso_pin: 12
+substitutions:
+  clk_pin: GPIO14
+  mosi_pin: GPIO13
+  miso_pin: GPIO12
+  cs_pin: GPIO15
 
-display:
-  - platform: max7219
-    cs_pin: 15
-    num_chips: 1
-    lambda: |-
-      it.print("01234567");
+<<: !include common.yaml
diff --git a/tests/components/max7219/test.rp2040-ard.yaml b/tests/components/max7219/test.rp2040-ard.yaml
index 37b2220649..f6c3f1eeca 100644
--- a/tests/components/max7219/test.rp2040-ard.yaml
+++ b/tests/components/max7219/test.rp2040-ard.yaml
@@ -1,12 +1,7 @@
-spi:
-  - id: spi_max6675
-    clk_pin: 2
-    mosi_pin: 3
-    miso_pin: 4
+substitutions:
+  clk_pin: GPIO2
+  mosi_pin: GPIO3
+  miso_pin: GPIO4
+  cs_pin: GPIO5
 
-display:
-  - platform: max7219
-    cs_pin: 6
-    num_chips: 1
-    lambda: |-
-      it.print("01234567");
+<<: !include common.yaml
diff --git a/tests/components/max7219digit/common.yaml b/tests/components/max7219digit/common.yaml
new file mode 100644
index 0000000000..a5a3bd57fb
--- /dev/null
+++ b/tests/components/max7219digit/common.yaml
@@ -0,0 +1,16 @@
+spi:
+  - id: spi_max7219digit
+    clk_pin: ${clk_pin}
+    mosi_pin: ${mosi_pin}
+    miso_pin: ${miso_pin}
+
+display:
+  - platform: max7219digit
+    cs_pin: ${cs_pin}
+    num_chips: 4
+    rotate_chip: 0
+    intensity: 10
+    scroll_mode: STOP
+    id: my_matrix
+    lambda: |-
+      it.printdigit("hello");
diff --git a/tests/components/max7219digit/test.esp32-ard.yaml b/tests/components/max7219digit/test.esp32-ard.yaml
index 7f3aed964a..54e027a614 100644
--- a/tests/components/max7219digit/test.esp32-ard.yaml
+++ b/tests/components/max7219digit/test.esp32-ard.yaml
@@ -1,16 +1,7 @@
-spi:
-  - id: spi_max7219digit
-    clk_pin: 16
-    mosi_pin: 17
-    miso_pin: 15
+substitutions:
+  clk_pin: GPIO16
+  mosi_pin: GPIO17
+  miso_pin: GPIO15
+  cs_pin: GPIO5
 
-display:
-  - platform: max7219digit
-    cs_pin: 12
-    num_chips: 4
-    rotate_chip: 0
-    intensity: 10
-    scroll_mode: STOP
-    id: my_matrix
-    lambda: |-
-      it.printdigit("hello");
+<<: !include common.yaml
diff --git a/tests/components/max7219digit/test.esp32-c3-ard.yaml b/tests/components/max7219digit/test.esp32-c3-ard.yaml
index 0c04784380..2415ba5dc6 100644
--- a/tests/components/max7219digit/test.esp32-c3-ard.yaml
+++ b/tests/components/max7219digit/test.esp32-c3-ard.yaml
@@ -1,16 +1,7 @@
-spi:
-  - id: spi_max7219digit
-    clk_pin: 6
-    mosi_pin: 7
-    miso_pin: 5
+substitutions:
+  clk_pin: GPIO6
+  mosi_pin: GPIO7
+  miso_pin: GPIO5
+  cs_pin: GPIO8
 
-display:
-  - platform: max7219digit
-    cs_pin: 8
-    num_chips: 4
-    rotate_chip: 0
-    intensity: 10
-    scroll_mode: STOP
-    id: my_matrix
-    lambda: |-
-      it.printdigit("hello");
+<<: !include common.yaml
diff --git a/tests/components/max7219digit/test.esp32-c3-idf.yaml b/tests/components/max7219digit/test.esp32-c3-idf.yaml
index 0c04784380..2415ba5dc6 100644
--- a/tests/components/max7219digit/test.esp32-c3-idf.yaml
+++ b/tests/components/max7219digit/test.esp32-c3-idf.yaml
@@ -1,16 +1,7 @@
-spi:
-  - id: spi_max7219digit
-    clk_pin: 6
-    mosi_pin: 7
-    miso_pin: 5
+substitutions:
+  clk_pin: GPIO6
+  mosi_pin: GPIO7
+  miso_pin: GPIO5
+  cs_pin: GPIO8
 
-display:
-  - platform: max7219digit
-    cs_pin: 8
-    num_chips: 4
-    rotate_chip: 0
-    intensity: 10
-    scroll_mode: STOP
-    id: my_matrix
-    lambda: |-
-      it.printdigit("hello");
+<<: !include common.yaml
diff --git a/tests/components/max7219digit/test.esp32-idf.yaml b/tests/components/max7219digit/test.esp32-idf.yaml
index 7f3aed964a..54e027a614 100644
--- a/tests/components/max7219digit/test.esp32-idf.yaml
+++ b/tests/components/max7219digit/test.esp32-idf.yaml
@@ -1,16 +1,7 @@
-spi:
-  - id: spi_max7219digit
-    clk_pin: 16
-    mosi_pin: 17
-    miso_pin: 15
+substitutions:
+  clk_pin: GPIO16
+  mosi_pin: GPIO17
+  miso_pin: GPIO15
+  cs_pin: GPIO5
 
-display:
-  - platform: max7219digit
-    cs_pin: 12
-    num_chips: 4
-    rotate_chip: 0
-    intensity: 10
-    scroll_mode: STOP
-    id: my_matrix
-    lambda: |-
-      it.printdigit("hello");
+<<: !include common.yaml
diff --git a/tests/components/max7219digit/test.esp8266-ard.yaml b/tests/components/max7219digit/test.esp8266-ard.yaml
index 52587e8b0e..dbd158d030 100644
--- a/tests/components/max7219digit/test.esp8266-ard.yaml
+++ b/tests/components/max7219digit/test.esp8266-ard.yaml
@@ -1,16 +1,7 @@
-spi:
-  - id: spi_max7219digit
-    clk_pin: 14
-    mosi_pin: 13
-    miso_pin: 12
+substitutions:
+  clk_pin: GPIO14
+  mosi_pin: GPIO13
+  miso_pin: GPIO12
+  cs_pin: GPIO15
 
-display:
-  - platform: max7219digit
-    cs_pin: 15
-    num_chips: 4
-    rotate_chip: 0
-    intensity: 10
-    scroll_mode: STOP
-    id: my_matrix
-    lambda: |-
-      it.printdigit("hello");
+<<: !include common.yaml
diff --git a/tests/components/max7219digit/test.rp2040-ard.yaml b/tests/components/max7219digit/test.rp2040-ard.yaml
index f986483ec2..f6c3f1eeca 100644
--- a/tests/components/max7219digit/test.rp2040-ard.yaml
+++ b/tests/components/max7219digit/test.rp2040-ard.yaml
@@ -1,16 +1,7 @@
-spi:
-  - id: spi_max7219digit
-    clk_pin: 2
-    mosi_pin: 3
-    miso_pin: 4
+substitutions:
+  clk_pin: GPIO2
+  mosi_pin: GPIO3
+  miso_pin: GPIO4
+  cs_pin: GPIO5
 
-display:
-  - platform: max7219digit
-    cs_pin: 6
-    num_chips: 4
-    rotate_chip: 0
-    intensity: 10
-    scroll_mode: STOP
-    id: my_matrix
-    lambda: |-
-      it.printdigit("hello");
+<<: !include common.yaml
diff --git a/tests/components/max9611/common.yaml b/tests/components/max9611/common.yaml
new file mode 100644
index 0000000000..c3c00fdf85
--- /dev/null
+++ b/tests/components/max9611/common.yaml
@@ -0,0 +1,18 @@
+i2c:
+  - id: i2c_max9611
+    scl: ${scl_pin}
+    sda: ${sda_pin}
+
+sensor:
+  - platform: max9611
+    shunt_resistance: 0.2 ohm
+    gain: 1X
+    voltage:
+      name: Max9611 Voltage
+    current:
+      name: Max9611 Current
+    power:
+      name: Max9611 Watts
+    temperature:
+      name: Max9611 Temperature
+    update_interval: 1s
diff --git a/tests/components/max9611/test.esp32-ard.yaml b/tests/components/max9611/test.esp32-ard.yaml
index 5c480cc815..63c3bd6afd 100644
--- a/tests/components/max9611/test.esp32-ard.yaml
+++ b/tests/components/max9611/test.esp32-ard.yaml
@@ -1,18 +1,5 @@
-i2c:
-  - id: i2c_max9611
-    scl: 16
-    sda: 17
+substitutions:
+  scl_pin: GPIO16
+  sda_pin: GPIO17
 
-sensor:
-  - platform: max9611
-    shunt_resistance: 0.2 ohm
-    gain: 1X
-    voltage:
-      name: Max9611 Voltage
-    current:
-      name: Max9611 Current
-    power:
-      name: Max9611 Watts
-    temperature:
-      name: Max9611 Temp
-    update_interval: 1s
+<<: !include common.yaml
diff --git a/tests/components/max9611/test.esp32-c3-ard.yaml b/tests/components/max9611/test.esp32-c3-ard.yaml
index 00f8330280..ee2c29ca4e 100644
--- a/tests/components/max9611/test.esp32-c3-ard.yaml
+++ b/tests/components/max9611/test.esp32-c3-ard.yaml
@@ -1,18 +1,5 @@
-i2c:
-  - id: i2c_max9611
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: max9611
-    shunt_resistance: 0.2 ohm
-    gain: 1X
-    voltage:
-      name: Max9611 Voltage
-    current:
-      name: Max9611 Current
-    power:
-      name: Max9611 Watts
-    temperature:
-      name: Max9611 Temp
-    update_interval: 1s
+<<: !include common.yaml
diff --git a/tests/components/max9611/test.esp32-c3-idf.yaml b/tests/components/max9611/test.esp32-c3-idf.yaml
index 00f8330280..ee2c29ca4e 100644
--- a/tests/components/max9611/test.esp32-c3-idf.yaml
+++ b/tests/components/max9611/test.esp32-c3-idf.yaml
@@ -1,18 +1,5 @@
-i2c:
-  - id: i2c_max9611
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: max9611
-    shunt_resistance: 0.2 ohm
-    gain: 1X
-    voltage:
-      name: Max9611 Voltage
-    current:
-      name: Max9611 Current
-    power:
-      name: Max9611 Watts
-    temperature:
-      name: Max9611 Temp
-    update_interval: 1s
+<<: !include common.yaml
diff --git a/tests/components/max9611/test.esp32-idf.yaml b/tests/components/max9611/test.esp32-idf.yaml
index 5c480cc815..63c3bd6afd 100644
--- a/tests/components/max9611/test.esp32-idf.yaml
+++ b/tests/components/max9611/test.esp32-idf.yaml
@@ -1,18 +1,5 @@
-i2c:
-  - id: i2c_max9611
-    scl: 16
-    sda: 17
+substitutions:
+  scl_pin: GPIO16
+  sda_pin: GPIO17
 
-sensor:
-  - platform: max9611
-    shunt_resistance: 0.2 ohm
-    gain: 1X
-    voltage:
-      name: Max9611 Voltage
-    current:
-      name: Max9611 Current
-    power:
-      name: Max9611 Watts
-    temperature:
-      name: Max9611 Temp
-    update_interval: 1s
+<<: !include common.yaml
diff --git a/tests/components/max9611/test.esp8266-ard.yaml b/tests/components/max9611/test.esp8266-ard.yaml
index 00f8330280..ee2c29ca4e 100644
--- a/tests/components/max9611/test.esp8266-ard.yaml
+++ b/tests/components/max9611/test.esp8266-ard.yaml
@@ -1,18 +1,5 @@
-i2c:
-  - id: i2c_max9611
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: max9611
-    shunt_resistance: 0.2 ohm
-    gain: 1X
-    voltage:
-      name: Max9611 Voltage
-    current:
-      name: Max9611 Current
-    power:
-      name: Max9611 Watts
-    temperature:
-      name: Max9611 Temp
-    update_interval: 1s
+<<: !include common.yaml
diff --git a/tests/components/max9611/test.rp2040-ard.yaml b/tests/components/max9611/test.rp2040-ard.yaml
index 00f8330280..ee2c29ca4e 100644
--- a/tests/components/max9611/test.rp2040-ard.yaml
+++ b/tests/components/max9611/test.rp2040-ard.yaml
@@ -1,18 +1,5 @@
-i2c:
-  - id: i2c_max9611
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: max9611
-    shunt_resistance: 0.2 ohm
-    gain: 1X
-    voltage:
-      name: Max9611 Voltage
-    current:
-      name: Max9611 Current
-    power:
-      name: Max9611 Watts
-    temperature:
-      name: Max9611 Temp
-    update_interval: 1s
+<<: !include common.yaml
diff --git a/tests/components/mcp23008/common.yaml b/tests/components/mcp23008/common.yaml
new file mode 100644
index 0000000000..1954766d25
--- /dev/null
+++ b/tests/components/mcp23008/common.yaml
@@ -0,0 +1,23 @@
+i2c:
+  - id: i2c_mcp23008
+    scl: ${scl_pin}
+    sda: ${sda_pin}
+
+mcp23008:
+  id: mcp23008_hub
+
+binary_sensor:
+  - platform: gpio
+    id: mcp23008_binary_sensor
+    pin:
+      mcp23xxx: mcp23008_hub
+      number: 0
+      mode: INPUT
+
+switch:
+  - platform: gpio
+    id: mcp23008_switch
+    pin:
+      mcp23xxx: mcp23008_hub
+      number: 1
+      mode: OUTPUT
diff --git a/tests/components/mcp23008/test.esp32-ard.yaml b/tests/components/mcp23008/test.esp32-ard.yaml
index cbf03f371c..63c3bd6afd 100644
--- a/tests/components/mcp23008/test.esp32-ard.yaml
+++ b/tests/components/mcp23008/test.esp32-ard.yaml
@@ -1,23 +1,5 @@
-i2c:
-  - id: i2c_mcp23008
-    scl: 16
-    sda: 17
+substitutions:
+  scl_pin: GPIO16
+  sda_pin: GPIO17
 
-mcp23008:
-  id: mcp23008_hub
-
-binary_sensor:
-  - platform: gpio
-    id: mcp23008_binary_sensor
-    pin:
-      mcp23xxx: mcp23008_hub
-      number: 0
-      mode: INPUT
-
-switch:
-  - platform: gpio
-    id: mcp23008_switch
-    pin:
-      mcp23xxx: mcp23008_hub
-      number: 1
-      mode: OUTPUT
+<<: !include common.yaml
diff --git a/tests/components/mcp23008/test.esp32-c3-ard.yaml b/tests/components/mcp23008/test.esp32-c3-ard.yaml
index eabd5a7311..ee2c29ca4e 100644
--- a/tests/components/mcp23008/test.esp32-c3-ard.yaml
+++ b/tests/components/mcp23008/test.esp32-c3-ard.yaml
@@ -1,23 +1,5 @@
-i2c:
-  - id: i2c_mcp23008
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-mcp23008:
-  id: mcp23008_hub
-
-binary_sensor:
-  - platform: gpio
-    id: mcp23008_binary_sensor
-    pin:
-      mcp23xxx: mcp23008_hub
-      number: 0
-      mode: INPUT
-
-switch:
-  - platform: gpio
-    id: mcp23008_switch
-    pin:
-      mcp23xxx: mcp23008_hub
-      number: 1
-      mode: OUTPUT
+<<: !include common.yaml
diff --git a/tests/components/mcp23008/test.esp32-c3-idf.yaml b/tests/components/mcp23008/test.esp32-c3-idf.yaml
index eabd5a7311..ee2c29ca4e 100644
--- a/tests/components/mcp23008/test.esp32-c3-idf.yaml
+++ b/tests/components/mcp23008/test.esp32-c3-idf.yaml
@@ -1,23 +1,5 @@
-i2c:
-  - id: i2c_mcp23008
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-mcp23008:
-  id: mcp23008_hub
-
-binary_sensor:
-  - platform: gpio
-    id: mcp23008_binary_sensor
-    pin:
-      mcp23xxx: mcp23008_hub
-      number: 0
-      mode: INPUT
-
-switch:
-  - platform: gpio
-    id: mcp23008_switch
-    pin:
-      mcp23xxx: mcp23008_hub
-      number: 1
-      mode: OUTPUT
+<<: !include common.yaml
diff --git a/tests/components/mcp23008/test.esp32-idf.yaml b/tests/components/mcp23008/test.esp32-idf.yaml
index cbf03f371c..63c3bd6afd 100644
--- a/tests/components/mcp23008/test.esp32-idf.yaml
+++ b/tests/components/mcp23008/test.esp32-idf.yaml
@@ -1,23 +1,5 @@
-i2c:
-  - id: i2c_mcp23008
-    scl: 16
-    sda: 17
+substitutions:
+  scl_pin: GPIO16
+  sda_pin: GPIO17
 
-mcp23008:
-  id: mcp23008_hub
-
-binary_sensor:
-  - platform: gpio
-    id: mcp23008_binary_sensor
-    pin:
-      mcp23xxx: mcp23008_hub
-      number: 0
-      mode: INPUT
-
-switch:
-  - platform: gpio
-    id: mcp23008_switch
-    pin:
-      mcp23xxx: mcp23008_hub
-      number: 1
-      mode: OUTPUT
+<<: !include common.yaml
diff --git a/tests/components/mcp23008/test.esp8266-ard.yaml b/tests/components/mcp23008/test.esp8266-ard.yaml
index eabd5a7311..ee2c29ca4e 100644
--- a/tests/components/mcp23008/test.esp8266-ard.yaml
+++ b/tests/components/mcp23008/test.esp8266-ard.yaml
@@ -1,23 +1,5 @@
-i2c:
-  - id: i2c_mcp23008
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-mcp23008:
-  id: mcp23008_hub
-
-binary_sensor:
-  - platform: gpio
-    id: mcp23008_binary_sensor
-    pin:
-      mcp23xxx: mcp23008_hub
-      number: 0
-      mode: INPUT
-
-switch:
-  - platform: gpio
-    id: mcp23008_switch
-    pin:
-      mcp23xxx: mcp23008_hub
-      number: 1
-      mode: OUTPUT
+<<: !include common.yaml
diff --git a/tests/components/mcp23008/test.rp2040-ard.yaml b/tests/components/mcp23008/test.rp2040-ard.yaml
index eabd5a7311..ee2c29ca4e 100644
--- a/tests/components/mcp23008/test.rp2040-ard.yaml
+++ b/tests/components/mcp23008/test.rp2040-ard.yaml
@@ -1,23 +1,5 @@
-i2c:
-  - id: i2c_mcp23008
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-mcp23008:
-  id: mcp23008_hub
-
-binary_sensor:
-  - platform: gpio
-    id: mcp23008_binary_sensor
-    pin:
-      mcp23xxx: mcp23008_hub
-      number: 0
-      mode: INPUT
-
-switch:
-  - platform: gpio
-    id: mcp23008_switch
-    pin:
-      mcp23xxx: mcp23008_hub
-      number: 1
-      mode: OUTPUT
+<<: !include common.yaml
diff --git a/tests/components/mcp23016/common.yaml b/tests/components/mcp23016/common.yaml
new file mode 100644
index 0000000000..109cb34b21
--- /dev/null
+++ b/tests/components/mcp23016/common.yaml
@@ -0,0 +1,23 @@
+i2c:
+  - id: i2c_mcp23016
+    scl: ${scl_pin}
+    sda: ${sda_pin}
+
+mcp23016:
+  id: mcp23016_hub
+
+binary_sensor:
+  - platform: gpio
+    id: mcp23016_binary_sensor
+    pin:
+      mcp23016: mcp23016_hub
+      number: 0
+      mode: INPUT
+
+switch:
+  - platform: gpio
+    id: mcp23016_switch
+    pin:
+      mcp23016: mcp23016_hub
+      number: 1
+      mode: OUTPUT
diff --git a/tests/components/mcp23016/test.esp32-ard.yaml b/tests/components/mcp23016/test.esp32-ard.yaml
index 48574a9b01..63c3bd6afd 100644
--- a/tests/components/mcp23016/test.esp32-ard.yaml
+++ b/tests/components/mcp23016/test.esp32-ard.yaml
@@ -1,23 +1,5 @@
-i2c:
-  - id: i2c_mcp23016
-    scl: 16
-    sda: 17
+substitutions:
+  scl_pin: GPIO16
+  sda_pin: GPIO17
 
-mcp23016:
-  id: mcp23016_hub
-
-binary_sensor:
-  - platform: gpio
-    id: mcp23016_binary_sensor
-    pin:
-      mcp23016: mcp23016_hub
-      number: 0
-      mode: INPUT
-
-switch:
-  - platform: gpio
-    id: mcp23016_switch
-    pin:
-      mcp23016: mcp23016_hub
-      number: 1
-      mode: OUTPUT
+<<: !include common.yaml
diff --git a/tests/components/mcp23016/test.esp32-c3-ard.yaml b/tests/components/mcp23016/test.esp32-c3-ard.yaml
index 2211931e3d..ee2c29ca4e 100644
--- a/tests/components/mcp23016/test.esp32-c3-ard.yaml
+++ b/tests/components/mcp23016/test.esp32-c3-ard.yaml
@@ -1,23 +1,5 @@
-i2c:
-  - id: i2c_mcp23016
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-mcp23016:
-  id: mcp23016_hub
-
-binary_sensor:
-  - platform: gpio
-    id: mcp23016_binary_sensor
-    pin:
-      mcp23016: mcp23016_hub
-      number: 0
-      mode: INPUT
-
-switch:
-  - platform: gpio
-    id: mcp23016_switch
-    pin:
-      mcp23016: mcp23016_hub
-      number: 1
-      mode: OUTPUT
+<<: !include common.yaml
diff --git a/tests/components/mcp23016/test.esp32-c3-idf.yaml b/tests/components/mcp23016/test.esp32-c3-idf.yaml
index 2211931e3d..ee2c29ca4e 100644
--- a/tests/components/mcp23016/test.esp32-c3-idf.yaml
+++ b/tests/components/mcp23016/test.esp32-c3-idf.yaml
@@ -1,23 +1,5 @@
-i2c:
-  - id: i2c_mcp23016
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-mcp23016:
-  id: mcp23016_hub
-
-binary_sensor:
-  - platform: gpio
-    id: mcp23016_binary_sensor
-    pin:
-      mcp23016: mcp23016_hub
-      number: 0
-      mode: INPUT
-
-switch:
-  - platform: gpio
-    id: mcp23016_switch
-    pin:
-      mcp23016: mcp23016_hub
-      number: 1
-      mode: OUTPUT
+<<: !include common.yaml
diff --git a/tests/components/mcp23016/test.esp32-idf.yaml b/tests/components/mcp23016/test.esp32-idf.yaml
index 48574a9b01..63c3bd6afd 100644
--- a/tests/components/mcp23016/test.esp32-idf.yaml
+++ b/tests/components/mcp23016/test.esp32-idf.yaml
@@ -1,23 +1,5 @@
-i2c:
-  - id: i2c_mcp23016
-    scl: 16
-    sda: 17
+substitutions:
+  scl_pin: GPIO16
+  sda_pin: GPIO17
 
-mcp23016:
-  id: mcp23016_hub
-
-binary_sensor:
-  - platform: gpio
-    id: mcp23016_binary_sensor
-    pin:
-      mcp23016: mcp23016_hub
-      number: 0
-      mode: INPUT
-
-switch:
-  - platform: gpio
-    id: mcp23016_switch
-    pin:
-      mcp23016: mcp23016_hub
-      number: 1
-      mode: OUTPUT
+<<: !include common.yaml
diff --git a/tests/components/mcp23016/test.esp8266-ard.yaml b/tests/components/mcp23016/test.esp8266-ard.yaml
index 2211931e3d..ee2c29ca4e 100644
--- a/tests/components/mcp23016/test.esp8266-ard.yaml
+++ b/tests/components/mcp23016/test.esp8266-ard.yaml
@@ -1,23 +1,5 @@
-i2c:
-  - id: i2c_mcp23016
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-mcp23016:
-  id: mcp23016_hub
-
-binary_sensor:
-  - platform: gpio
-    id: mcp23016_binary_sensor
-    pin:
-      mcp23016: mcp23016_hub
-      number: 0
-      mode: INPUT
-
-switch:
-  - platform: gpio
-    id: mcp23016_switch
-    pin:
-      mcp23016: mcp23016_hub
-      number: 1
-      mode: OUTPUT
+<<: !include common.yaml
diff --git a/tests/components/mcp23016/test.rp2040-ard.yaml b/tests/components/mcp23016/test.rp2040-ard.yaml
index 2211931e3d..ee2c29ca4e 100644
--- a/tests/components/mcp23016/test.rp2040-ard.yaml
+++ b/tests/components/mcp23016/test.rp2040-ard.yaml
@@ -1,23 +1,5 @@
-i2c:
-  - id: i2c_mcp23016
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-mcp23016:
-  id: mcp23016_hub
-
-binary_sensor:
-  - platform: gpio
-    id: mcp23016_binary_sensor
-    pin:
-      mcp23016: mcp23016_hub
-      number: 0
-      mode: INPUT
-
-switch:
-  - platform: gpio
-    id: mcp23016_switch
-    pin:
-      mcp23016: mcp23016_hub
-      number: 1
-      mode: OUTPUT
+<<: !include common.yaml
diff --git a/tests/components/mcp23017/common.yaml b/tests/components/mcp23017/common.yaml
new file mode 100644
index 0000000000..74949bba76
--- /dev/null
+++ b/tests/components/mcp23017/common.yaml
@@ -0,0 +1,23 @@
+i2c:
+  - id: i2c_mcp23017
+    scl: ${scl_pin}
+    sda: ${sda_pin}
+
+mcp23017:
+  id: mcp23017_hub
+
+binary_sensor:
+  - platform: gpio
+    id: mcp23017_binary_sensor
+    pin:
+      mcp23xxx: mcp23017_hub
+      number: 0
+      mode: INPUT
+
+switch:
+  - platform: gpio
+    id: mcp23017_switch
+    pin:
+      mcp23xxx: mcp23017_hub
+      number: 1
+      mode: OUTPUT
diff --git a/tests/components/mcp23017/test.esp32-ard.yaml b/tests/components/mcp23017/test.esp32-ard.yaml
index 9b7c45eb8a..63c3bd6afd 100644
--- a/tests/components/mcp23017/test.esp32-ard.yaml
+++ b/tests/components/mcp23017/test.esp32-ard.yaml
@@ -1,23 +1,5 @@
-i2c:
-  - id: i2c_mcp23017
-    scl: 16
-    sda: 17
+substitutions:
+  scl_pin: GPIO16
+  sda_pin: GPIO17
 
-mcp23017:
-  id: mcp23017_hub
-
-binary_sensor:
-  - platform: gpio
-    id: mcp23017_binary_sensor
-    pin:
-      mcp23xxx: mcp23017_hub
-      number: 0
-      mode: INPUT
-
-switch:
-  - platform: gpio
-    id: mcp23017_switch
-    pin:
-      mcp23xxx: mcp23017_hub
-      number: 1
-      mode: OUTPUT
+<<: !include common.yaml
diff --git a/tests/components/mcp23017/test.esp32-c3-ard.yaml b/tests/components/mcp23017/test.esp32-c3-ard.yaml
index 863b2b8f0b..ee2c29ca4e 100644
--- a/tests/components/mcp23017/test.esp32-c3-ard.yaml
+++ b/tests/components/mcp23017/test.esp32-c3-ard.yaml
@@ -1,23 +1,5 @@
-i2c:
-  - id: i2c_mcp23017
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-mcp23017:
-  id: mcp23017_hub
-
-binary_sensor:
-  - platform: gpio
-    id: mcp23017_binary_sensor
-    pin:
-      mcp23xxx: mcp23017_hub
-      number: 0
-      mode: INPUT
-
-switch:
-  - platform: gpio
-    id: mcp23017_switch
-    pin:
-      mcp23xxx: mcp23017_hub
-      number: 1
-      mode: OUTPUT
+<<: !include common.yaml
diff --git a/tests/components/mcp23017/test.esp32-c3-idf.yaml b/tests/components/mcp23017/test.esp32-c3-idf.yaml
index 863b2b8f0b..ee2c29ca4e 100644
--- a/tests/components/mcp23017/test.esp32-c3-idf.yaml
+++ b/tests/components/mcp23017/test.esp32-c3-idf.yaml
@@ -1,23 +1,5 @@
-i2c:
-  - id: i2c_mcp23017
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-mcp23017:
-  id: mcp23017_hub
-
-binary_sensor:
-  - platform: gpio
-    id: mcp23017_binary_sensor
-    pin:
-      mcp23xxx: mcp23017_hub
-      number: 0
-      mode: INPUT
-
-switch:
-  - platform: gpio
-    id: mcp23017_switch
-    pin:
-      mcp23xxx: mcp23017_hub
-      number: 1
-      mode: OUTPUT
+<<: !include common.yaml
diff --git a/tests/components/mcp23017/test.esp32-idf.yaml b/tests/components/mcp23017/test.esp32-idf.yaml
index 9b7c45eb8a..63c3bd6afd 100644
--- a/tests/components/mcp23017/test.esp32-idf.yaml
+++ b/tests/components/mcp23017/test.esp32-idf.yaml
@@ -1,23 +1,5 @@
-i2c:
-  - id: i2c_mcp23017
-    scl: 16
-    sda: 17
+substitutions:
+  scl_pin: GPIO16
+  sda_pin: GPIO17
 
-mcp23017:
-  id: mcp23017_hub
-
-binary_sensor:
-  - platform: gpio
-    id: mcp23017_binary_sensor
-    pin:
-      mcp23xxx: mcp23017_hub
-      number: 0
-      mode: INPUT
-
-switch:
-  - platform: gpio
-    id: mcp23017_switch
-    pin:
-      mcp23xxx: mcp23017_hub
-      number: 1
-      mode: OUTPUT
+<<: !include common.yaml
diff --git a/tests/components/mcp23017/test.esp8266-ard.yaml b/tests/components/mcp23017/test.esp8266-ard.yaml
index 863b2b8f0b..ee2c29ca4e 100644
--- a/tests/components/mcp23017/test.esp8266-ard.yaml
+++ b/tests/components/mcp23017/test.esp8266-ard.yaml
@@ -1,23 +1,5 @@
-i2c:
-  - id: i2c_mcp23017
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-mcp23017:
-  id: mcp23017_hub
-
-binary_sensor:
-  - platform: gpio
-    id: mcp23017_binary_sensor
-    pin:
-      mcp23xxx: mcp23017_hub
-      number: 0
-      mode: INPUT
-
-switch:
-  - platform: gpio
-    id: mcp23017_switch
-    pin:
-      mcp23xxx: mcp23017_hub
-      number: 1
-      mode: OUTPUT
+<<: !include common.yaml
diff --git a/tests/components/mcp23017/test.rp2040-ard.yaml b/tests/components/mcp23017/test.rp2040-ard.yaml
index 863b2b8f0b..ee2c29ca4e 100644
--- a/tests/components/mcp23017/test.rp2040-ard.yaml
+++ b/tests/components/mcp23017/test.rp2040-ard.yaml
@@ -1,23 +1,5 @@
-i2c:
-  - id: i2c_mcp23017
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-mcp23017:
-  id: mcp23017_hub
-
-binary_sensor:
-  - platform: gpio
-    id: mcp23017_binary_sensor
-    pin:
-      mcp23xxx: mcp23017_hub
-      number: 0
-      mode: INPUT
-
-switch:
-  - platform: gpio
-    id: mcp23017_switch
-    pin:
-      mcp23xxx: mcp23017_hub
-      number: 1
-      mode: OUTPUT
+<<: !include common.yaml
diff --git a/tests/components/mcp23s08/common.yaml b/tests/components/mcp23s08/common.yaml
new file mode 100644
index 0000000000..b89088fe15
--- /dev/null
+++ b/tests/components/mcp23s08/common.yaml
@@ -0,0 +1,10 @@
+spi:
+  - id: spi_mcp23s08
+    clk_pin: ${clk_pin}
+    mosi_pin: ${mosi_pin}
+    miso_pin: ${miso_pin}
+
+mcp23s08:
+  - id: mcp23s08_hub
+    cs_pin: ${cs_pin}
+    deviceaddress: 0
diff --git a/tests/components/mcp23s08/test.esp32-ard.yaml b/tests/components/mcp23s08/test.esp32-ard.yaml
index 0b26035c3e..54e027a614 100644
--- a/tests/components/mcp23s08/test.esp32-ard.yaml
+++ b/tests/components/mcp23s08/test.esp32-ard.yaml
@@ -1,10 +1,7 @@
-spi:
-  - id: spi_mcp23s08
-    clk_pin: 16
-    mosi_pin: 17
-    miso_pin: 15
+substitutions:
+  clk_pin: GPIO16
+  mosi_pin: GPIO17
+  miso_pin: GPIO15
+  cs_pin: GPIO5
 
-mcp23s08:
-  - id: mcp23s08_hub
-    cs_pin: 12
-    deviceaddress: 0
+<<: !include common.yaml
diff --git a/tests/components/mcp23s08/test.esp32-c3-ard.yaml b/tests/components/mcp23s08/test.esp32-c3-ard.yaml
index f1af8a71a9..2415ba5dc6 100644
--- a/tests/components/mcp23s08/test.esp32-c3-ard.yaml
+++ b/tests/components/mcp23s08/test.esp32-c3-ard.yaml
@@ -1,10 +1,7 @@
-spi:
-  - id: spi_mcp23s08
-    clk_pin: 6
-    mosi_pin: 7
-    miso_pin: 5
+substitutions:
+  clk_pin: GPIO6
+  mosi_pin: GPIO7
+  miso_pin: GPIO5
+  cs_pin: GPIO8
 
-mcp23s08:
-  - id: mcp23s08_hub
-    cs_pin: 8
-    deviceaddress: 0
+<<: !include common.yaml
diff --git a/tests/components/mcp23s08/test.esp32-c3-idf.yaml b/tests/components/mcp23s08/test.esp32-c3-idf.yaml
index f1af8a71a9..2415ba5dc6 100644
--- a/tests/components/mcp23s08/test.esp32-c3-idf.yaml
+++ b/tests/components/mcp23s08/test.esp32-c3-idf.yaml
@@ -1,10 +1,7 @@
-spi:
-  - id: spi_mcp23s08
-    clk_pin: 6
-    mosi_pin: 7
-    miso_pin: 5
+substitutions:
+  clk_pin: GPIO6
+  mosi_pin: GPIO7
+  miso_pin: GPIO5
+  cs_pin: GPIO8
 
-mcp23s08:
-  - id: mcp23s08_hub
-    cs_pin: 8
-    deviceaddress: 0
+<<: !include common.yaml
diff --git a/tests/components/mcp23s08/test.esp32-idf.yaml b/tests/components/mcp23s08/test.esp32-idf.yaml
index 0b26035c3e..54e027a614 100644
--- a/tests/components/mcp23s08/test.esp32-idf.yaml
+++ b/tests/components/mcp23s08/test.esp32-idf.yaml
@@ -1,10 +1,7 @@
-spi:
-  - id: spi_mcp23s08
-    clk_pin: 16
-    mosi_pin: 17
-    miso_pin: 15
+substitutions:
+  clk_pin: GPIO16
+  mosi_pin: GPIO17
+  miso_pin: GPIO15
+  cs_pin: GPIO5
 
-mcp23s08:
-  - id: mcp23s08_hub
-    cs_pin: 12
-    deviceaddress: 0
+<<: !include common.yaml
diff --git a/tests/components/mcp23s08/test.esp8266-ard.yaml b/tests/components/mcp23s08/test.esp8266-ard.yaml
index eff856aca9..dbd158d030 100644
--- a/tests/components/mcp23s08/test.esp8266-ard.yaml
+++ b/tests/components/mcp23s08/test.esp8266-ard.yaml
@@ -1,10 +1,7 @@
-spi:
-  - id: spi_mcp23s08
-    clk_pin: 14
-    mosi_pin: 13
-    miso_pin: 12
+substitutions:
+  clk_pin: GPIO14
+  mosi_pin: GPIO13
+  miso_pin: GPIO12
+  cs_pin: GPIO15
 
-mcp23s08:
-  - id: mcp23s08_hub
-    cs_pin: 15
-    deviceaddress: 0
+<<: !include common.yaml
diff --git a/tests/components/mcp23s08/test.rp2040-ard.yaml b/tests/components/mcp23s08/test.rp2040-ard.yaml
index 1b23d2d3b5..f6c3f1eeca 100644
--- a/tests/components/mcp23s08/test.rp2040-ard.yaml
+++ b/tests/components/mcp23s08/test.rp2040-ard.yaml
@@ -1,10 +1,7 @@
-spi:
-  - id: spi_mcp23s08
-    clk_pin: 2
-    mosi_pin: 3
-    miso_pin: 4
+substitutions:
+  clk_pin: GPIO2
+  mosi_pin: GPIO3
+  miso_pin: GPIO4
+  cs_pin: GPIO5
 
-mcp23s08:
-  - id: mcp23s08_hub
-    cs_pin: 6
-    deviceaddress: 0
+<<: !include common.yaml
diff --git a/tests/components/mcp23s17/common.yaml b/tests/components/mcp23s17/common.yaml
new file mode 100644
index 0000000000..3fb27ef625
--- /dev/null
+++ b/tests/components/mcp23s17/common.yaml
@@ -0,0 +1,10 @@
+spi:
+  - id: spi_mcp23s17
+    clk_pin: ${clk_pin}
+    mosi_pin: ${mosi_pin}
+    miso_pin: ${miso_pin}
+
+mcp23s17:
+  - id: mcp23s17_hub
+    cs_pin: ${cs_pin}
+    deviceaddress: 0
diff --git a/tests/components/mcp23s17/test.esp32-ard.yaml b/tests/components/mcp23s17/test.esp32-ard.yaml
index 9a42c12e85..54e027a614 100644
--- a/tests/components/mcp23s17/test.esp32-ard.yaml
+++ b/tests/components/mcp23s17/test.esp32-ard.yaml
@@ -1,10 +1,7 @@
-spi:
-  - id: spi_mcp23s17
-    clk_pin: 16
-    mosi_pin: 17
-    miso_pin: 15
+substitutions:
+  clk_pin: GPIO16
+  mosi_pin: GPIO17
+  miso_pin: GPIO15
+  cs_pin: GPIO5
 
-mcp23s17:
-  - id: mcp23s17_hub
-    cs_pin: 12
-    deviceaddress: 0
+<<: !include common.yaml
diff --git a/tests/components/mcp23s17/test.esp32-c3-ard.yaml b/tests/components/mcp23s17/test.esp32-c3-ard.yaml
index d83f66d3b1..2415ba5dc6 100644
--- a/tests/components/mcp23s17/test.esp32-c3-ard.yaml
+++ b/tests/components/mcp23s17/test.esp32-c3-ard.yaml
@@ -1,10 +1,7 @@
-spi:
-  - id: spi_mcp23s17
-    clk_pin: 6
-    mosi_pin: 7
-    miso_pin: 5
+substitutions:
+  clk_pin: GPIO6
+  mosi_pin: GPIO7
+  miso_pin: GPIO5
+  cs_pin: GPIO8
 
-mcp23s17:
-  - id: mcp23s17_hub
-    cs_pin: 8
-    deviceaddress: 0
+<<: !include common.yaml
diff --git a/tests/components/mcp23s17/test.esp32-c3-idf.yaml b/tests/components/mcp23s17/test.esp32-c3-idf.yaml
index d83f66d3b1..2415ba5dc6 100644
--- a/tests/components/mcp23s17/test.esp32-c3-idf.yaml
+++ b/tests/components/mcp23s17/test.esp32-c3-idf.yaml
@@ -1,10 +1,7 @@
-spi:
-  - id: spi_mcp23s17
-    clk_pin: 6
-    mosi_pin: 7
-    miso_pin: 5
+substitutions:
+  clk_pin: GPIO6
+  mosi_pin: GPIO7
+  miso_pin: GPIO5
+  cs_pin: GPIO8
 
-mcp23s17:
-  - id: mcp23s17_hub
-    cs_pin: 8
-    deviceaddress: 0
+<<: !include common.yaml
diff --git a/tests/components/mcp23s17/test.esp32-idf.yaml b/tests/components/mcp23s17/test.esp32-idf.yaml
index 9a42c12e85..54e027a614 100644
--- a/tests/components/mcp23s17/test.esp32-idf.yaml
+++ b/tests/components/mcp23s17/test.esp32-idf.yaml
@@ -1,10 +1,7 @@
-spi:
-  - id: spi_mcp23s17
-    clk_pin: 16
-    mosi_pin: 17
-    miso_pin: 15
+substitutions:
+  clk_pin: GPIO16
+  mosi_pin: GPIO17
+  miso_pin: GPIO15
+  cs_pin: GPIO5
 
-mcp23s17:
-  - id: mcp23s17_hub
-    cs_pin: 12
-    deviceaddress: 0
+<<: !include common.yaml
diff --git a/tests/components/mcp23s17/test.esp8266-ard.yaml b/tests/components/mcp23s17/test.esp8266-ard.yaml
index 36dac63f6f..dbd158d030 100644
--- a/tests/components/mcp23s17/test.esp8266-ard.yaml
+++ b/tests/components/mcp23s17/test.esp8266-ard.yaml
@@ -1,10 +1,7 @@
-spi:
-  - id: spi_mcp23s17
-    clk_pin: 14
-    mosi_pin: 13
-    miso_pin: 12
+substitutions:
+  clk_pin: GPIO14
+  mosi_pin: GPIO13
+  miso_pin: GPIO12
+  cs_pin: GPIO15
 
-mcp23s17:
-  - id: mcp23s17_hub
-    cs_pin: 15
-    deviceaddress: 0
+<<: !include common.yaml
diff --git a/tests/components/mcp23s17/test.rp2040-ard.yaml b/tests/components/mcp23s17/test.rp2040-ard.yaml
index 2730f6a9d6..f6c3f1eeca 100644
--- a/tests/components/mcp23s17/test.rp2040-ard.yaml
+++ b/tests/components/mcp23s17/test.rp2040-ard.yaml
@@ -1,10 +1,7 @@
-spi:
-  - id: spi_mcp23s17
-    clk_pin: 2
-    mosi_pin: 3
-    miso_pin: 4
+substitutions:
+  clk_pin: GPIO2
+  mosi_pin: GPIO3
+  miso_pin: GPIO4
+  cs_pin: GPIO5
 
-mcp23s17:
-  - id: mcp23s17_hub
-    cs_pin: 6
-    deviceaddress: 0
+<<: !include common.yaml
diff --git a/tests/components/mcp2515/common.yaml b/tests/components/mcp2515/common.yaml
new file mode 100644
index 0000000000..96a72a3ec3
--- /dev/null
+++ b/tests/components/mcp2515/common.yaml
@@ -0,0 +1,44 @@
+spi:
+  - id: spi_mcp2515
+    clk_pin: ${clk_pin}
+    mosi_pin: ${mosi_pin}
+    miso_pin: ${miso_pin}
+
+canbus:
+  - platform: mcp2515
+    id: mcp2515_can
+    cs_pin: ${cs_pin}
+    can_id: 4
+    bit_rate: 50kbps
+    on_frame:
+      - can_id: 500
+        then:
+          - lambda: |-
+              std::string b(x.begin(), x.end());
+              ESP_LOGD("can_id 500", "%s", b.c_str());
+      - can_id: 23
+        then:
+          - if:
+              condition:
+                lambda: "return x[0] == 0x11;"
+              then:
+                logger.log: "x[0] == 0x11"
+      - can_id: 0b00000000000000000000001000000
+        can_id_mask: 0b11111000000000011111111000000
+        use_extended_id: true
+        then:
+          - lambda: |-
+              auto pdo_id = can_id >> 14;
+              switch (pdo_id)
+              {
+                case 117:
+                  ESP_LOGD("canbus", "exhaust_fan_duty");
+                  break;
+                case 118:
+                  ESP_LOGD("canbus", "supply_fan_duty");
+                  break;
+                case 119:
+                  ESP_LOGD("canbus", "supply_fan_flow");
+                  break;
+                // to be continued...
+              }
diff --git a/tests/components/mcp2515/test.esp32-ard.yaml b/tests/components/mcp2515/test.esp32-ard.yaml
index 07fae36cc3..54e027a614 100644
--- a/tests/components/mcp2515/test.esp32-ard.yaml
+++ b/tests/components/mcp2515/test.esp32-ard.yaml
@@ -1,44 +1,7 @@
-spi:
-  - id: spi_mcp2515
-    clk_pin: 16
-    mosi_pin: 17
-    miso_pin: 15
+substitutions:
+  clk_pin: GPIO16
+  mosi_pin: GPIO17
+  miso_pin: GPIO15
+  cs_pin: GPIO5
 
-canbus:
-  - platform: mcp2515
-    id: mcp2515_can
-    cs_pin: 12
-    can_id: 4
-    bit_rate: 50kbps
-    on_frame:
-      - can_id: 500
-        then:
-          - lambda: |-
-              std::string b(x.begin(), x.end());
-              ESP_LOGD("can_id 500", "%s", b.c_str());
-      - can_id: 23
-        then:
-          - if:
-              condition:
-                lambda: "return x[0] == 0x11;"
-              then:
-                logger.log: "x[0] == 0x11"
-      - can_id: 0b00000000000000000000001000000
-        can_id_mask: 0b11111000000000011111111000000
-        use_extended_id: true
-        then:
-          - lambda: |-
-              auto pdo_id = can_id >> 14;
-              switch (pdo_id)
-              {
-                case 117:
-                  ESP_LOGD("canbus", "exhaust_fan_duty");
-                  break;
-                case 118:
-                  ESP_LOGD("canbus", "supply_fan_duty");
-                  break;
-                case 119:
-                  ESP_LOGD("canbus", "supply_fan_flow");
-                  break;
-                // to be continued...
-              }
+<<: !include common.yaml
diff --git a/tests/components/mcp2515/test.esp32-c3-ard.yaml b/tests/components/mcp2515/test.esp32-c3-ard.yaml
index 3ceeea268f..2415ba5dc6 100644
--- a/tests/components/mcp2515/test.esp32-c3-ard.yaml
+++ b/tests/components/mcp2515/test.esp32-c3-ard.yaml
@@ -1,44 +1,7 @@
-spi:
-  - id: spi_mcp2515
-    clk_pin: 6
-    mosi_pin: 7
-    miso_pin: 5
+substitutions:
+  clk_pin: GPIO6
+  mosi_pin: GPIO7
+  miso_pin: GPIO5
+  cs_pin: GPIO8
 
-canbus:
-  - platform: mcp2515
-    id: mcp2515_can
-    cs_pin: 8
-    can_id: 4
-    bit_rate: 50kbps
-    on_frame:
-      - can_id: 500
-        then:
-          - lambda: |-
-              std::string b(x.begin(), x.end());
-              ESP_LOGD("can_id 500", "%s", b.c_str());
-      - can_id: 23
-        then:
-          - if:
-              condition:
-                lambda: "return x[0] == 0x11;"
-              then:
-                logger.log: "x[0] == 0x11"
-      - can_id: 0b00000000000000000000001000000
-        can_id_mask: 0b11111000000000011111111000000
-        use_extended_id: true
-        then:
-          - lambda: |-
-              auto pdo_id = can_id >> 14;
-              switch (pdo_id)
-              {
-                case 117:
-                  ESP_LOGD("canbus", "exhaust_fan_duty");
-                  break;
-                case 118:
-                  ESP_LOGD("canbus", "supply_fan_duty");
-                  break;
-                case 119:
-                  ESP_LOGD("canbus", "supply_fan_flow");
-                  break;
-                // to be continued...
-              }
+<<: !include common.yaml
diff --git a/tests/components/mcp2515/test.esp32-c3-idf.yaml b/tests/components/mcp2515/test.esp32-c3-idf.yaml
index 3ceeea268f..2415ba5dc6 100644
--- a/tests/components/mcp2515/test.esp32-c3-idf.yaml
+++ b/tests/components/mcp2515/test.esp32-c3-idf.yaml
@@ -1,44 +1,7 @@
-spi:
-  - id: spi_mcp2515
-    clk_pin: 6
-    mosi_pin: 7
-    miso_pin: 5
+substitutions:
+  clk_pin: GPIO6
+  mosi_pin: GPIO7
+  miso_pin: GPIO5
+  cs_pin: GPIO8
 
-canbus:
-  - platform: mcp2515
-    id: mcp2515_can
-    cs_pin: 8
-    can_id: 4
-    bit_rate: 50kbps
-    on_frame:
-      - can_id: 500
-        then:
-          - lambda: |-
-              std::string b(x.begin(), x.end());
-              ESP_LOGD("can_id 500", "%s", b.c_str());
-      - can_id: 23
-        then:
-          - if:
-              condition:
-                lambda: "return x[0] == 0x11;"
-              then:
-                logger.log: "x[0] == 0x11"
-      - can_id: 0b00000000000000000000001000000
-        can_id_mask: 0b11111000000000011111111000000
-        use_extended_id: true
-        then:
-          - lambda: |-
-              auto pdo_id = can_id >> 14;
-              switch (pdo_id)
-              {
-                case 117:
-                  ESP_LOGD("canbus", "exhaust_fan_duty");
-                  break;
-                case 118:
-                  ESP_LOGD("canbus", "supply_fan_duty");
-                  break;
-                case 119:
-                  ESP_LOGD("canbus", "supply_fan_flow");
-                  break;
-                // to be continued...
-              }
+<<: !include common.yaml
diff --git a/tests/components/mcp2515/test.esp32-idf.yaml b/tests/components/mcp2515/test.esp32-idf.yaml
index 07fae36cc3..54e027a614 100644
--- a/tests/components/mcp2515/test.esp32-idf.yaml
+++ b/tests/components/mcp2515/test.esp32-idf.yaml
@@ -1,44 +1,7 @@
-spi:
-  - id: spi_mcp2515
-    clk_pin: 16
-    mosi_pin: 17
-    miso_pin: 15
+substitutions:
+  clk_pin: GPIO16
+  mosi_pin: GPIO17
+  miso_pin: GPIO15
+  cs_pin: GPIO5
 
-canbus:
-  - platform: mcp2515
-    id: mcp2515_can
-    cs_pin: 12
-    can_id: 4
-    bit_rate: 50kbps
-    on_frame:
-      - can_id: 500
-        then:
-          - lambda: |-
-              std::string b(x.begin(), x.end());
-              ESP_LOGD("can_id 500", "%s", b.c_str());
-      - can_id: 23
-        then:
-          - if:
-              condition:
-                lambda: "return x[0] == 0x11;"
-              then:
-                logger.log: "x[0] == 0x11"
-      - can_id: 0b00000000000000000000001000000
-        can_id_mask: 0b11111000000000011111111000000
-        use_extended_id: true
-        then:
-          - lambda: |-
-              auto pdo_id = can_id >> 14;
-              switch (pdo_id)
-              {
-                case 117:
-                  ESP_LOGD("canbus", "exhaust_fan_duty");
-                  break;
-                case 118:
-                  ESP_LOGD("canbus", "supply_fan_duty");
-                  break;
-                case 119:
-                  ESP_LOGD("canbus", "supply_fan_flow");
-                  break;
-                // to be continued...
-              }
+<<: !include common.yaml
diff --git a/tests/components/mcp2515/test.esp8266-ard.yaml b/tests/components/mcp2515/test.esp8266-ard.yaml
index 1096a0e809..dbd158d030 100644
--- a/tests/components/mcp2515/test.esp8266-ard.yaml
+++ b/tests/components/mcp2515/test.esp8266-ard.yaml
@@ -1,44 +1,7 @@
-spi:
-  - id: spi_mcp2515
-    clk_pin: 14
-    mosi_pin: 13
-    miso_pin: 12
+substitutions:
+  clk_pin: GPIO14
+  mosi_pin: GPIO13
+  miso_pin: GPIO12
+  cs_pin: GPIO15
 
-canbus:
-  - platform: mcp2515
-    id: mcp2515_can
-    cs_pin: 15
-    can_id: 4
-    bit_rate: 50kbps
-    on_frame:
-      - can_id: 500
-        then:
-          - lambda: |-
-              std::string b(x.begin(), x.end());
-              ESP_LOGD("can_id 500", "%s", b.c_str());
-      - can_id: 23
-        then:
-          - if:
-              condition:
-                lambda: "return x[0] == 0x11;"
-              then:
-                logger.log: "x[0] == 0x11"
-      - can_id: 0b00000000000000000000001000000
-        can_id_mask: 0b11111000000000011111111000000
-        use_extended_id: true
-        then:
-          - lambda: |-
-              auto pdo_id = can_id >> 14;
-              switch (pdo_id)
-              {
-                case 117:
-                  ESP_LOGD("canbus", "exhaust_fan_duty");
-                  break;
-                case 118:
-                  ESP_LOGD("canbus", "supply_fan_duty");
-                  break;
-                case 119:
-                  ESP_LOGD("canbus", "supply_fan_flow");
-                  break;
-                // to be continued...
-              }
+<<: !include common.yaml
diff --git a/tests/components/mcp2515/test.rp2040-ard.yaml b/tests/components/mcp2515/test.rp2040-ard.yaml
index 678c817d3d..f6c3f1eeca 100644
--- a/tests/components/mcp2515/test.rp2040-ard.yaml
+++ b/tests/components/mcp2515/test.rp2040-ard.yaml
@@ -1,44 +1,7 @@
-spi:
-  - id: spi_mcp2515
-    clk_pin: 2
-    mosi_pin: 3
-    miso_pin: 4
+substitutions:
+  clk_pin: GPIO2
+  mosi_pin: GPIO3
+  miso_pin: GPIO4
+  cs_pin: GPIO5
 
-canbus:
-  - platform: mcp2515
-    id: mcp2515_can
-    cs_pin: 6
-    can_id: 4
-    bit_rate: 50kbps
-    on_frame:
-      - can_id: 500
-        then:
-          - lambda: |-
-              std::string b(x.begin(), x.end());
-              ESP_LOGD("can_id 500", "%s", b.c_str());
-      - can_id: 23
-        then:
-          - if:
-              condition:
-                lambda: "return x[0] == 0x11;"
-              then:
-                logger.log: "x[0] == 0x11"
-      - can_id: 0b00000000000000000000001000000
-        can_id_mask: 0b11111000000000011111111000000
-        use_extended_id: true
-        then:
-          - lambda: |-
-              auto pdo_id = can_id >> 14;
-              switch (pdo_id)
-              {
-                case 117:
-                  ESP_LOGD("canbus", "exhaust_fan_duty");
-                  break;
-                case 118:
-                  ESP_LOGD("canbus", "supply_fan_duty");
-                  break;
-                case 119:
-                  ESP_LOGD("canbus", "supply_fan_flow");
-                  break;
-                // to be continued...
-              }
+<<: !include common.yaml
diff --git a/tests/components/mcp3008/common.yaml b/tests/components/mcp3008/common.yaml
new file mode 100644
index 0000000000..646d3a20e9
--- /dev/null
+++ b/tests/components/mcp3008/common.yaml
@@ -0,0 +1,17 @@
+spi:
+  - id: spi_mcp3008
+    clk_pin: ${clk_pin}
+    mosi_pin: ${mosi_pin}
+    miso_pin: ${miso_pin}
+
+mcp3008:
+  - id: mcp3008_hub
+    cs_pin: ${cs_pin}
+
+sensor:
+  - platform: mcp3008
+    id: mcp3008_sensor
+    mcp3008_id: mcp3008_hub
+    number: 0
+    reference_voltage: 3.19
+    update_interval: 5s
diff --git a/tests/components/mcp3008/test.esp32-ard.yaml b/tests/components/mcp3008/test.esp32-ard.yaml
index a66fbeb7a1..54e027a614 100644
--- a/tests/components/mcp3008/test.esp32-ard.yaml
+++ b/tests/components/mcp3008/test.esp32-ard.yaml
@@ -1,17 +1,7 @@
-spi:
-  - id: spi_mcp3008
-    clk_pin: 16
-    mosi_pin: 17
-    miso_pin: 15
+substitutions:
+  clk_pin: GPIO16
+  mosi_pin: GPIO17
+  miso_pin: GPIO15
+  cs_pin: GPIO5
 
-mcp3008:
-  - id: mcp3008_hub
-    cs_pin: 12
-
-sensor:
-  - platform: mcp3008
-    id: mcp3008_sensor
-    mcp3008_id: mcp3008_hub
-    number: 0
-    reference_voltage: 3.19
-    update_interval: 5s
+<<: !include common.yaml
diff --git a/tests/components/mcp3008/test.esp32-c3-ard.yaml b/tests/components/mcp3008/test.esp32-c3-ard.yaml
index 9e66372e4f..2415ba5dc6 100644
--- a/tests/components/mcp3008/test.esp32-c3-ard.yaml
+++ b/tests/components/mcp3008/test.esp32-c3-ard.yaml
@@ -1,17 +1,7 @@
-spi:
-  - id: spi_mcp3008
-    clk_pin: 6
-    mosi_pin: 7
-    miso_pin: 5
+substitutions:
+  clk_pin: GPIO6
+  mosi_pin: GPIO7
+  miso_pin: GPIO5
+  cs_pin: GPIO8
 
-mcp3008:
-  - id: mcp3008_hub
-    cs_pin: 8
-
-sensor:
-  - platform: mcp3008
-    id: mcp3008_sensor
-    mcp3008_id: mcp3008_hub
-    number: 0
-    reference_voltage: 3.19
-    update_interval: 5s
+<<: !include common.yaml
diff --git a/tests/components/mcp3008/test.esp32-c3-idf.yaml b/tests/components/mcp3008/test.esp32-c3-idf.yaml
index 9e66372e4f..2415ba5dc6 100644
--- a/tests/components/mcp3008/test.esp32-c3-idf.yaml
+++ b/tests/components/mcp3008/test.esp32-c3-idf.yaml
@@ -1,17 +1,7 @@
-spi:
-  - id: spi_mcp3008
-    clk_pin: 6
-    mosi_pin: 7
-    miso_pin: 5
+substitutions:
+  clk_pin: GPIO6
+  mosi_pin: GPIO7
+  miso_pin: GPIO5
+  cs_pin: GPIO8
 
-mcp3008:
-  - id: mcp3008_hub
-    cs_pin: 8
-
-sensor:
-  - platform: mcp3008
-    id: mcp3008_sensor
-    mcp3008_id: mcp3008_hub
-    number: 0
-    reference_voltage: 3.19
-    update_interval: 5s
+<<: !include common.yaml
diff --git a/tests/components/mcp3008/test.esp32-idf.yaml b/tests/components/mcp3008/test.esp32-idf.yaml
index a66fbeb7a1..54e027a614 100644
--- a/tests/components/mcp3008/test.esp32-idf.yaml
+++ b/tests/components/mcp3008/test.esp32-idf.yaml
@@ -1,17 +1,7 @@
-spi:
-  - id: spi_mcp3008
-    clk_pin: 16
-    mosi_pin: 17
-    miso_pin: 15
+substitutions:
+  clk_pin: GPIO16
+  mosi_pin: GPIO17
+  miso_pin: GPIO15
+  cs_pin: GPIO5
 
-mcp3008:
-  - id: mcp3008_hub
-    cs_pin: 12
-
-sensor:
-  - platform: mcp3008
-    id: mcp3008_sensor
-    mcp3008_id: mcp3008_hub
-    number: 0
-    reference_voltage: 3.19
-    update_interval: 5s
+<<: !include common.yaml
diff --git a/tests/components/mcp3008/test.esp8266-ard.yaml b/tests/components/mcp3008/test.esp8266-ard.yaml
index eaccca0765..dbd158d030 100644
--- a/tests/components/mcp3008/test.esp8266-ard.yaml
+++ b/tests/components/mcp3008/test.esp8266-ard.yaml
@@ -1,17 +1,7 @@
-spi:
-  - id: spi_mcp3008
-    clk_pin: 14
-    mosi_pin: 13
-    miso_pin: 12
+substitutions:
+  clk_pin: GPIO14
+  mosi_pin: GPIO13
+  miso_pin: GPIO12
+  cs_pin: GPIO15
 
-mcp3008:
-  - id: mcp3008_hub
-    cs_pin: 15
-
-sensor:
-  - platform: mcp3008
-    id: mcp3008_sensor
-    mcp3008_id: mcp3008_hub
-    number: 0
-    reference_voltage: 3.19
-    update_interval: 5s
+<<: !include common.yaml
diff --git a/tests/components/mcp3008/test.rp2040-ard.yaml b/tests/components/mcp3008/test.rp2040-ard.yaml
index 8ab9630553..f6c3f1eeca 100644
--- a/tests/components/mcp3008/test.rp2040-ard.yaml
+++ b/tests/components/mcp3008/test.rp2040-ard.yaml
@@ -1,17 +1,7 @@
-spi:
-  - id: spi_mcp3008
-    clk_pin: 2
-    mosi_pin: 3
-    miso_pin: 4
+substitutions:
+  clk_pin: GPIO2
+  mosi_pin: GPIO3
+  miso_pin: GPIO4
+  cs_pin: GPIO5
 
-mcp3008:
-  - id: mcp3008_hub
-    cs_pin: 6
-
-sensor:
-  - platform: mcp3008
-    id: mcp3008_sensor
-    mcp3008_id: mcp3008_hub
-    number: 0
-    reference_voltage: 3.19
-    update_interval: 5s
+<<: !include common.yaml
diff --git a/tests/components/mcp3204/common.yaml b/tests/components/mcp3204/common.yaml
new file mode 100644
index 0000000000..f102500c81
--- /dev/null
+++ b/tests/components/mcp3204/common.yaml
@@ -0,0 +1,16 @@
+spi:
+  - id: spi_mcp3204
+    clk_pin: ${clk_pin}
+    mosi_pin: ${mosi_pin}
+    miso_pin: ${miso_pin}
+
+mcp3204:
+  - id: mcp3204_hub
+    cs_pin: ${cs_pin}
+
+sensor:
+  - platform: mcp3204
+    id: mcp3204_sensor
+    mcp3204_id: mcp3204_hub
+    number: 0
+    update_interval: 5s
diff --git a/tests/components/mcp3204/test.esp32-ard.yaml b/tests/components/mcp3204/test.esp32-ard.yaml
index c340797c8e..54e027a614 100644
--- a/tests/components/mcp3204/test.esp32-ard.yaml
+++ b/tests/components/mcp3204/test.esp32-ard.yaml
@@ -1,16 +1,7 @@
-spi:
-  - id: spi_mcp3204
-    clk_pin: 16
-    mosi_pin: 17
-    miso_pin: 15
+substitutions:
+  clk_pin: GPIO16
+  mosi_pin: GPIO17
+  miso_pin: GPIO15
+  cs_pin: GPIO5
 
-mcp3204:
-  - id: mcp3204_hub
-    cs_pin: 12
-
-sensor:
-  - platform: mcp3204
-    id: mcp3204_sensor
-    mcp3204_id: mcp3204_hub
-    number: 0
-    update_interval: 5s
+<<: !include common.yaml
diff --git a/tests/components/mcp3204/test.esp32-c3-ard.yaml b/tests/components/mcp3204/test.esp32-c3-ard.yaml
index 5bf5ba81e1..2415ba5dc6 100644
--- a/tests/components/mcp3204/test.esp32-c3-ard.yaml
+++ b/tests/components/mcp3204/test.esp32-c3-ard.yaml
@@ -1,16 +1,7 @@
-spi:
-  - id: spi_mcp3204
-    clk_pin: 6
-    mosi_pin: 7
-    miso_pin: 5
+substitutions:
+  clk_pin: GPIO6
+  mosi_pin: GPIO7
+  miso_pin: GPIO5
+  cs_pin: GPIO8
 
-mcp3204:
-  - id: mcp3204_hub
-    cs_pin: 8
-
-sensor:
-  - platform: mcp3204
-    id: mcp3204_sensor
-    mcp3204_id: mcp3204_hub
-    number: 0
-    update_interval: 5s
+<<: !include common.yaml
diff --git a/tests/components/mcp3204/test.esp32-c3-idf.yaml b/tests/components/mcp3204/test.esp32-c3-idf.yaml
index 5bf5ba81e1..2415ba5dc6 100644
--- a/tests/components/mcp3204/test.esp32-c3-idf.yaml
+++ b/tests/components/mcp3204/test.esp32-c3-idf.yaml
@@ -1,16 +1,7 @@
-spi:
-  - id: spi_mcp3204
-    clk_pin: 6
-    mosi_pin: 7
-    miso_pin: 5
+substitutions:
+  clk_pin: GPIO6
+  mosi_pin: GPIO7
+  miso_pin: GPIO5
+  cs_pin: GPIO8
 
-mcp3204:
-  - id: mcp3204_hub
-    cs_pin: 8
-
-sensor:
-  - platform: mcp3204
-    id: mcp3204_sensor
-    mcp3204_id: mcp3204_hub
-    number: 0
-    update_interval: 5s
+<<: !include common.yaml
diff --git a/tests/components/mcp3204/test.esp32-idf.yaml b/tests/components/mcp3204/test.esp32-idf.yaml
index c340797c8e..54e027a614 100644
--- a/tests/components/mcp3204/test.esp32-idf.yaml
+++ b/tests/components/mcp3204/test.esp32-idf.yaml
@@ -1,16 +1,7 @@
-spi:
-  - id: spi_mcp3204
-    clk_pin: 16
-    mosi_pin: 17
-    miso_pin: 15
+substitutions:
+  clk_pin: GPIO16
+  mosi_pin: GPIO17
+  miso_pin: GPIO15
+  cs_pin: GPIO5
 
-mcp3204:
-  - id: mcp3204_hub
-    cs_pin: 12
-
-sensor:
-  - platform: mcp3204
-    id: mcp3204_sensor
-    mcp3204_id: mcp3204_hub
-    number: 0
-    update_interval: 5s
+<<: !include common.yaml
diff --git a/tests/components/mcp3204/test.esp8266-ard.yaml b/tests/components/mcp3204/test.esp8266-ard.yaml
index d208e3e06c..dbd158d030 100644
--- a/tests/components/mcp3204/test.esp8266-ard.yaml
+++ b/tests/components/mcp3204/test.esp8266-ard.yaml
@@ -1,16 +1,7 @@
-spi:
-  - id: spi_mcp3204
-    clk_pin: 14
-    mosi_pin: 13
-    miso_pin: 12
+substitutions:
+  clk_pin: GPIO14
+  mosi_pin: GPIO13
+  miso_pin: GPIO12
+  cs_pin: GPIO15
 
-mcp3204:
-  - id: mcp3204_hub
-    cs_pin: 15
-
-sensor:
-  - platform: mcp3204
-    id: mcp3204_sensor
-    mcp3204_id: mcp3204_hub
-    number: 0
-    update_interval: 5s
+<<: !include common.yaml
diff --git a/tests/components/mcp3204/test.rp2040-ard.yaml b/tests/components/mcp3204/test.rp2040-ard.yaml
index 63f30e3621..f6c3f1eeca 100644
--- a/tests/components/mcp3204/test.rp2040-ard.yaml
+++ b/tests/components/mcp3204/test.rp2040-ard.yaml
@@ -1,16 +1,7 @@
-spi:
-  - id: spi_mcp3204
-    clk_pin: 2
-    mosi_pin: 3
-    miso_pin: 4
+substitutions:
+  clk_pin: GPIO2
+  mosi_pin: GPIO3
+  miso_pin: GPIO4
+  cs_pin: GPIO5
 
-mcp3204:
-  - id: mcp3204_hub
-    cs_pin: 6
-
-sensor:
-  - platform: mcp3204
-    id: mcp3204_sensor
-    mcp3204_id: mcp3204_hub
-    number: 0
-    update_interval: 5s
+<<: !include common.yaml
diff --git a/tests/components/mcp4725/common.yaml b/tests/components/mcp4725/common.yaml
new file mode 100644
index 0000000000..0ccc649f2e
--- /dev/null
+++ b/tests/components/mcp4725/common.yaml
@@ -0,0 +1,8 @@
+i2c:
+  - id: i2c_mcp4725
+    scl: ${scl_pin}
+    sda: ${sda_pin}
+
+output:
+  - platform: mcp4725
+    id: mcp4725_dac_output
diff --git a/tests/components/mcp4725/test.esp32-ard.yaml b/tests/components/mcp4725/test.esp32-ard.yaml
index a523ad95e1..63c3bd6afd 100644
--- a/tests/components/mcp4725/test.esp32-ard.yaml
+++ b/tests/components/mcp4725/test.esp32-ard.yaml
@@ -1,8 +1,5 @@
-i2c:
-  - id: i2c_mcp4725
-    scl: 16
-    sda: 17
+substitutions:
+  scl_pin: GPIO16
+  sda_pin: GPIO17
 
-output:
-  - platform: mcp4725
-    id: mcp4725_dac_output
+<<: !include common.yaml
diff --git a/tests/components/mcp4725/test.esp32-c3-ard.yaml b/tests/components/mcp4725/test.esp32-c3-ard.yaml
index 5fc799203d..ee2c29ca4e 100644
--- a/tests/components/mcp4725/test.esp32-c3-ard.yaml
+++ b/tests/components/mcp4725/test.esp32-c3-ard.yaml
@@ -1,8 +1,5 @@
-i2c:
-  - id: i2c_mcp4725
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-output:
-  - platform: mcp4725
-    id: mcp4725_dac_output
+<<: !include common.yaml
diff --git a/tests/components/mcp4725/test.esp32-c3-idf.yaml b/tests/components/mcp4725/test.esp32-c3-idf.yaml
index 5fc799203d..ee2c29ca4e 100644
--- a/tests/components/mcp4725/test.esp32-c3-idf.yaml
+++ b/tests/components/mcp4725/test.esp32-c3-idf.yaml
@@ -1,8 +1,5 @@
-i2c:
-  - id: i2c_mcp4725
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-output:
-  - platform: mcp4725
-    id: mcp4725_dac_output
+<<: !include common.yaml
diff --git a/tests/components/mcp4725/test.esp32-idf.yaml b/tests/components/mcp4725/test.esp32-idf.yaml
index a523ad95e1..63c3bd6afd 100644
--- a/tests/components/mcp4725/test.esp32-idf.yaml
+++ b/tests/components/mcp4725/test.esp32-idf.yaml
@@ -1,8 +1,5 @@
-i2c:
-  - id: i2c_mcp4725
-    scl: 16
-    sda: 17
+substitutions:
+  scl_pin: GPIO16
+  sda_pin: GPIO17
 
-output:
-  - platform: mcp4725
-    id: mcp4725_dac_output
+<<: !include common.yaml
diff --git a/tests/components/mcp4725/test.esp8266-ard.yaml b/tests/components/mcp4725/test.esp8266-ard.yaml
index 5fc799203d..ee2c29ca4e 100644
--- a/tests/components/mcp4725/test.esp8266-ard.yaml
+++ b/tests/components/mcp4725/test.esp8266-ard.yaml
@@ -1,8 +1,5 @@
-i2c:
-  - id: i2c_mcp4725
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-output:
-  - platform: mcp4725
-    id: mcp4725_dac_output
+<<: !include common.yaml
diff --git a/tests/components/mcp4725/test.rp2040-ard.yaml b/tests/components/mcp4725/test.rp2040-ard.yaml
index 5fc799203d..ee2c29ca4e 100644
--- a/tests/components/mcp4725/test.rp2040-ard.yaml
+++ b/tests/components/mcp4725/test.rp2040-ard.yaml
@@ -1,8 +1,5 @@
-i2c:
-  - id: i2c_mcp4725
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-output:
-  - platform: mcp4725
-    id: mcp4725_dac_output
+<<: !include common.yaml
diff --git a/tests/components/mcp4728/common.yaml b/tests/components/mcp4728/common.yaml
new file mode 100644
index 0000000000..b42818e4e6
--- /dev/null
+++ b/tests/components/mcp4728/common.yaml
@@ -0,0 +1,31 @@
+i2c:
+  - id: i2c_mcp4728
+    scl: ${scl_pin}
+    sda: ${sda_pin}
+
+mcp4728:
+  - id: mcp4728_dac
+
+output:
+  - platform: mcp4728
+    id: mcp4728_dac_output_a
+    channel: A
+    vref: vdd
+    power_down: normal
+  - platform: mcp4728
+    id: mcp4728_dac_output_b
+    channel: B
+    vref: internal
+    gain: X1
+    power_down: gnd_1k
+  - platform: mcp4728
+    id: mcp4728_dac_output_c
+    channel: C
+    vref: vdd
+    power_down: gnd_100k
+  - platform: mcp4728
+    id: mcp4728_dac_output_d
+    channel: D
+    vref: internal
+    gain: X2
+    power_down: gnd_500k
diff --git a/tests/components/mcp4728/test.esp32-ard.yaml b/tests/components/mcp4728/test.esp32-ard.yaml
index b29a6ee53c..63c3bd6afd 100644
--- a/tests/components/mcp4728/test.esp32-ard.yaml
+++ b/tests/components/mcp4728/test.esp32-ard.yaml
@@ -1,31 +1,5 @@
-i2c:
-  - id: i2c_mcp4728
-    scl: 16
-    sda: 17
+substitutions:
+  scl_pin: GPIO16
+  sda_pin: GPIO17
 
-mcp4728:
-  - id: mcp4728_dac
-
-output:
-  - platform: mcp4728
-    id: mcp4728_dac_output_a
-    channel: A
-    vref: vdd
-    power_down: normal
-  - platform: mcp4728
-    id: mcp4728_dac_output_b
-    channel: B
-    vref: internal
-    gain: X1
-    power_down: gnd_1k
-  - platform: mcp4728
-    id: mcp4728_dac_output_c
-    channel: C
-    vref: vdd
-    power_down: gnd_100k
-  - platform: mcp4728
-    id: mcp4728_dac_output_d
-    channel: D
-    vref: internal
-    gain: X2
-    power_down: gnd_500k
+<<: !include common.yaml
diff --git a/tests/components/mcp4728/test.esp32-c3-ard.yaml b/tests/components/mcp4728/test.esp32-c3-ard.yaml
index 2f24dd0b8c..ee2c29ca4e 100644
--- a/tests/components/mcp4728/test.esp32-c3-ard.yaml
+++ b/tests/components/mcp4728/test.esp32-c3-ard.yaml
@@ -1,31 +1,5 @@
-i2c:
-  - id: i2c_mcp4728
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-mcp4728:
-  - id: mcp4728_dac
-
-output:
-  - platform: mcp4728
-    id: mcp4728_dac_output_a
-    channel: A
-    vref: vdd
-    power_down: normal
-  - platform: mcp4728
-    id: mcp4728_dac_output_b
-    channel: B
-    vref: internal
-    gain: X1
-    power_down: gnd_1k
-  - platform: mcp4728
-    id: mcp4728_dac_output_c
-    channel: C
-    vref: vdd
-    power_down: gnd_100k
-  - platform: mcp4728
-    id: mcp4728_dac_output_d
-    channel: D
-    vref: internal
-    gain: X2
-    power_down: gnd_500k
+<<: !include common.yaml
diff --git a/tests/components/mcp4728/test.esp32-c3-idf.yaml b/tests/components/mcp4728/test.esp32-c3-idf.yaml
index 2f24dd0b8c..ee2c29ca4e 100644
--- a/tests/components/mcp4728/test.esp32-c3-idf.yaml
+++ b/tests/components/mcp4728/test.esp32-c3-idf.yaml
@@ -1,31 +1,5 @@
-i2c:
-  - id: i2c_mcp4728
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-mcp4728:
-  - id: mcp4728_dac
-
-output:
-  - platform: mcp4728
-    id: mcp4728_dac_output_a
-    channel: A
-    vref: vdd
-    power_down: normal
-  - platform: mcp4728
-    id: mcp4728_dac_output_b
-    channel: B
-    vref: internal
-    gain: X1
-    power_down: gnd_1k
-  - platform: mcp4728
-    id: mcp4728_dac_output_c
-    channel: C
-    vref: vdd
-    power_down: gnd_100k
-  - platform: mcp4728
-    id: mcp4728_dac_output_d
-    channel: D
-    vref: internal
-    gain: X2
-    power_down: gnd_500k
+<<: !include common.yaml
diff --git a/tests/components/mcp4728/test.esp32-idf.yaml b/tests/components/mcp4728/test.esp32-idf.yaml
index b29a6ee53c..63c3bd6afd 100644
--- a/tests/components/mcp4728/test.esp32-idf.yaml
+++ b/tests/components/mcp4728/test.esp32-idf.yaml
@@ -1,31 +1,5 @@
-i2c:
-  - id: i2c_mcp4728
-    scl: 16
-    sda: 17
+substitutions:
+  scl_pin: GPIO16
+  sda_pin: GPIO17
 
-mcp4728:
-  - id: mcp4728_dac
-
-output:
-  - platform: mcp4728
-    id: mcp4728_dac_output_a
-    channel: A
-    vref: vdd
-    power_down: normal
-  - platform: mcp4728
-    id: mcp4728_dac_output_b
-    channel: B
-    vref: internal
-    gain: X1
-    power_down: gnd_1k
-  - platform: mcp4728
-    id: mcp4728_dac_output_c
-    channel: C
-    vref: vdd
-    power_down: gnd_100k
-  - platform: mcp4728
-    id: mcp4728_dac_output_d
-    channel: D
-    vref: internal
-    gain: X2
-    power_down: gnd_500k
+<<: !include common.yaml
diff --git a/tests/components/mcp4728/test.esp8266-ard.yaml b/tests/components/mcp4728/test.esp8266-ard.yaml
index 2f24dd0b8c..ee2c29ca4e 100644
--- a/tests/components/mcp4728/test.esp8266-ard.yaml
+++ b/tests/components/mcp4728/test.esp8266-ard.yaml
@@ -1,31 +1,5 @@
-i2c:
-  - id: i2c_mcp4728
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-mcp4728:
-  - id: mcp4728_dac
-
-output:
-  - platform: mcp4728
-    id: mcp4728_dac_output_a
-    channel: A
-    vref: vdd
-    power_down: normal
-  - platform: mcp4728
-    id: mcp4728_dac_output_b
-    channel: B
-    vref: internal
-    gain: X1
-    power_down: gnd_1k
-  - platform: mcp4728
-    id: mcp4728_dac_output_c
-    channel: C
-    vref: vdd
-    power_down: gnd_100k
-  - platform: mcp4728
-    id: mcp4728_dac_output_d
-    channel: D
-    vref: internal
-    gain: X2
-    power_down: gnd_500k
+<<: !include common.yaml
diff --git a/tests/components/mcp4728/test.rp2040-ard.yaml b/tests/components/mcp4728/test.rp2040-ard.yaml
index 2f24dd0b8c..ee2c29ca4e 100644
--- a/tests/components/mcp4728/test.rp2040-ard.yaml
+++ b/tests/components/mcp4728/test.rp2040-ard.yaml
@@ -1,31 +1,5 @@
-i2c:
-  - id: i2c_mcp4728
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-mcp4728:
-  - id: mcp4728_dac
-
-output:
-  - platform: mcp4728
-    id: mcp4728_dac_output_a
-    channel: A
-    vref: vdd
-    power_down: normal
-  - platform: mcp4728
-    id: mcp4728_dac_output_b
-    channel: B
-    vref: internal
-    gain: X1
-    power_down: gnd_1k
-  - platform: mcp4728
-    id: mcp4728_dac_output_c
-    channel: C
-    vref: vdd
-    power_down: gnd_100k
-  - platform: mcp4728
-    id: mcp4728_dac_output_d
-    channel: D
-    vref: internal
-    gain: X2
-    power_down: gnd_500k
+<<: !include common.yaml
diff --git a/tests/components/mcp47a1/common.yaml b/tests/components/mcp47a1/common.yaml
new file mode 100644
index 0000000000..59e28d37b3
--- /dev/null
+++ b/tests/components/mcp47a1/common.yaml
@@ -0,0 +1,8 @@
+i2c:
+  - id: i2c_mcp47a1
+    scl: ${scl_pin}
+    sda: ${sda_pin}
+
+output:
+  - platform: mcp47a1
+    id: output_mcp47a1
diff --git a/tests/components/mcp47a1/test.esp32-ard.yaml b/tests/components/mcp47a1/test.esp32-ard.yaml
index 9e2133de66..63c3bd6afd 100644
--- a/tests/components/mcp47a1/test.esp32-ard.yaml
+++ b/tests/components/mcp47a1/test.esp32-ard.yaml
@@ -1,8 +1,5 @@
-i2c:
-  - id: i2c_mcp47a1
-    scl: 16
-    sda: 17
+substitutions:
+  scl_pin: GPIO16
+  sda_pin: GPIO17
 
-output:
-  - platform: mcp47a1
-    id: output_mcp47a1
+<<: !include common.yaml
diff --git a/tests/components/mcp47a1/test.esp32-c3-ard.yaml b/tests/components/mcp47a1/test.esp32-c3-ard.yaml
index 68273e00eb..ee2c29ca4e 100644
--- a/tests/components/mcp47a1/test.esp32-c3-ard.yaml
+++ b/tests/components/mcp47a1/test.esp32-c3-ard.yaml
@@ -1,8 +1,5 @@
-i2c:
-  - id: i2c_mcp47a1
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-output:
-  - platform: mcp47a1
-    id: output_mcp47a1
+<<: !include common.yaml
diff --git a/tests/components/mcp47a1/test.esp32-c3-idf.yaml b/tests/components/mcp47a1/test.esp32-c3-idf.yaml
index 68273e00eb..ee2c29ca4e 100644
--- a/tests/components/mcp47a1/test.esp32-c3-idf.yaml
+++ b/tests/components/mcp47a1/test.esp32-c3-idf.yaml
@@ -1,8 +1,5 @@
-i2c:
-  - id: i2c_mcp47a1
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-output:
-  - platform: mcp47a1
-    id: output_mcp47a1
+<<: !include common.yaml
diff --git a/tests/components/mcp47a1/test.esp32-idf.yaml b/tests/components/mcp47a1/test.esp32-idf.yaml
index 9e2133de66..63c3bd6afd 100644
--- a/tests/components/mcp47a1/test.esp32-idf.yaml
+++ b/tests/components/mcp47a1/test.esp32-idf.yaml
@@ -1,8 +1,5 @@
-i2c:
-  - id: i2c_mcp47a1
-    scl: 16
-    sda: 17
+substitutions:
+  scl_pin: GPIO16
+  sda_pin: GPIO17
 
-output:
-  - platform: mcp47a1
-    id: output_mcp47a1
+<<: !include common.yaml
diff --git a/tests/components/mcp47a1/test.esp8266-ard.yaml b/tests/components/mcp47a1/test.esp8266-ard.yaml
index 68273e00eb..ee2c29ca4e 100644
--- a/tests/components/mcp47a1/test.esp8266-ard.yaml
+++ b/tests/components/mcp47a1/test.esp8266-ard.yaml
@@ -1,8 +1,5 @@
-i2c:
-  - id: i2c_mcp47a1
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-output:
-  - platform: mcp47a1
-    id: output_mcp47a1
+<<: !include common.yaml
diff --git a/tests/components/mcp47a1/test.rp2040-ard.yaml b/tests/components/mcp47a1/test.rp2040-ard.yaml
index 68273e00eb..ee2c29ca4e 100644
--- a/tests/components/mcp47a1/test.rp2040-ard.yaml
+++ b/tests/components/mcp47a1/test.rp2040-ard.yaml
@@ -1,8 +1,5 @@
-i2c:
-  - id: i2c_mcp47a1
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-output:
-  - platform: mcp47a1
-    id: output_mcp47a1
+<<: !include common.yaml
diff --git a/tests/components/mcp9600/common.yaml b/tests/components/mcp9600/common.yaml
new file mode 100644
index 0000000000..e3c9df79e4
--- /dev/null
+++ b/tests/components/mcp9600/common.yaml
@@ -0,0 +1,12 @@
+i2c:
+  - id: i2c_mcp9600
+    scl: ${scl_pin}
+    sda: ${sda_pin}
+
+sensor:
+  - platform: mcp9600
+    thermocouple_type: K
+    hot_junction:
+      name: Thermocouple Temperature
+    cold_junction:
+      name: Ambient Temperature
diff --git a/tests/components/mcp9600/test.esp32-ard.yaml b/tests/components/mcp9600/test.esp32-ard.yaml
index 0c94f099ae..63c3bd6afd 100644
--- a/tests/components/mcp9600/test.esp32-ard.yaml
+++ b/tests/components/mcp9600/test.esp32-ard.yaml
@@ -1,12 +1,5 @@
-i2c:
-  - id: i2c_mcp9600
-    scl: 16
-    sda: 17
+substitutions:
+  scl_pin: GPIO16
+  sda_pin: GPIO17
 
-sensor:
-  - platform: mcp9600
-    thermocouple_type: K
-    hot_junction:
-      name: Thermocouple Temperature
-    cold_junction:
-      name: Ambient Temperature
+<<: !include common.yaml
diff --git a/tests/components/mcp9600/test.esp32-c3-ard.yaml b/tests/components/mcp9600/test.esp32-c3-ard.yaml
index b07f4589ce..ee2c29ca4e 100644
--- a/tests/components/mcp9600/test.esp32-c3-ard.yaml
+++ b/tests/components/mcp9600/test.esp32-c3-ard.yaml
@@ -1,12 +1,5 @@
-i2c:
-  - id: i2c_mcp9600
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: mcp9600
-    thermocouple_type: K
-    hot_junction:
-      name: Thermocouple Temperature
-    cold_junction:
-      name: Ambient Temperature
+<<: !include common.yaml
diff --git a/tests/components/mcp9600/test.esp32-c3-idf.yaml b/tests/components/mcp9600/test.esp32-c3-idf.yaml
index b07f4589ce..ee2c29ca4e 100644
--- a/tests/components/mcp9600/test.esp32-c3-idf.yaml
+++ b/tests/components/mcp9600/test.esp32-c3-idf.yaml
@@ -1,12 +1,5 @@
-i2c:
-  - id: i2c_mcp9600
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: mcp9600
-    thermocouple_type: K
-    hot_junction:
-      name: Thermocouple Temperature
-    cold_junction:
-      name: Ambient Temperature
+<<: !include common.yaml
diff --git a/tests/components/mcp9600/test.esp32-idf.yaml b/tests/components/mcp9600/test.esp32-idf.yaml
index 0c94f099ae..63c3bd6afd 100644
--- a/tests/components/mcp9600/test.esp32-idf.yaml
+++ b/tests/components/mcp9600/test.esp32-idf.yaml
@@ -1,12 +1,5 @@
-i2c:
-  - id: i2c_mcp9600
-    scl: 16
-    sda: 17
+substitutions:
+  scl_pin: GPIO16
+  sda_pin: GPIO17
 
-sensor:
-  - platform: mcp9600
-    thermocouple_type: K
-    hot_junction:
-      name: Thermocouple Temperature
-    cold_junction:
-      name: Ambient Temperature
+<<: !include common.yaml
diff --git a/tests/components/mcp9600/test.esp8266-ard.yaml b/tests/components/mcp9600/test.esp8266-ard.yaml
index b07f4589ce..ee2c29ca4e 100644
--- a/tests/components/mcp9600/test.esp8266-ard.yaml
+++ b/tests/components/mcp9600/test.esp8266-ard.yaml
@@ -1,12 +1,5 @@
-i2c:
-  - id: i2c_mcp9600
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: mcp9600
-    thermocouple_type: K
-    hot_junction:
-      name: Thermocouple Temperature
-    cold_junction:
-      name: Ambient Temperature
+<<: !include common.yaml
diff --git a/tests/components/mcp9600/test.rp2040-ard.yaml b/tests/components/mcp9600/test.rp2040-ard.yaml
index b07f4589ce..ee2c29ca4e 100644
--- a/tests/components/mcp9600/test.rp2040-ard.yaml
+++ b/tests/components/mcp9600/test.rp2040-ard.yaml
@@ -1,12 +1,5 @@
-i2c:
-  - id: i2c_mcp9600
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: mcp9600
-    thermocouple_type: K
-    hot_junction:
-      name: Thermocouple Temperature
-    cold_junction:
-      name: Ambient Temperature
+<<: !include common.yaml
diff --git a/tests/components/mcp9808/common.yaml b/tests/components/mcp9808/common.yaml
new file mode 100644
index 0000000000..ccfd5d13ce
--- /dev/null
+++ b/tests/components/mcp9808/common.yaml
@@ -0,0 +1,8 @@
+i2c:
+  - id: i2c_mcp9808
+    scl: ${scl_pin}
+    sda: ${sda_pin}
+
+sensor:
+  - platform: mcp9808
+    name: MCP9808 Temperature
diff --git a/tests/components/mcp9808/test.esp32-ard.yaml b/tests/components/mcp9808/test.esp32-ard.yaml
index 1e5affdac0..63c3bd6afd 100644
--- a/tests/components/mcp9808/test.esp32-ard.yaml
+++ b/tests/components/mcp9808/test.esp32-ard.yaml
@@ -1,8 +1,5 @@
-i2c:
-  - id: i2c_mcp9808
-    scl: 16
-    sda: 17
+substitutions:
+  scl_pin: GPIO16
+  sda_pin: GPIO17
 
-sensor:
-  - platform: mcp9808
-    name: MCP9808 Temperature
+<<: !include common.yaml
diff --git a/tests/components/mcp9808/test.esp32-c3-ard.yaml b/tests/components/mcp9808/test.esp32-c3-ard.yaml
index 86b4d7f181..ee2c29ca4e 100644
--- a/tests/components/mcp9808/test.esp32-c3-ard.yaml
+++ b/tests/components/mcp9808/test.esp32-c3-ard.yaml
@@ -1,8 +1,5 @@
-i2c:
-  - id: i2c_mcp9808
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: mcp9808
-    name: MCP9808 Temperature
+<<: !include common.yaml
diff --git a/tests/components/mcp9808/test.esp32-c3-idf.yaml b/tests/components/mcp9808/test.esp32-c3-idf.yaml
index 86b4d7f181..ee2c29ca4e 100644
--- a/tests/components/mcp9808/test.esp32-c3-idf.yaml
+++ b/tests/components/mcp9808/test.esp32-c3-idf.yaml
@@ -1,8 +1,5 @@
-i2c:
-  - id: i2c_mcp9808
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: mcp9808
-    name: MCP9808 Temperature
+<<: !include common.yaml
diff --git a/tests/components/mcp9808/test.esp32-idf.yaml b/tests/components/mcp9808/test.esp32-idf.yaml
index 1e5affdac0..63c3bd6afd 100644
--- a/tests/components/mcp9808/test.esp32-idf.yaml
+++ b/tests/components/mcp9808/test.esp32-idf.yaml
@@ -1,8 +1,5 @@
-i2c:
-  - id: i2c_mcp9808
-    scl: 16
-    sda: 17
+substitutions:
+  scl_pin: GPIO16
+  sda_pin: GPIO17
 
-sensor:
-  - platform: mcp9808
-    name: MCP9808 Temperature
+<<: !include common.yaml
diff --git a/tests/components/mcp9808/test.esp8266-ard.yaml b/tests/components/mcp9808/test.esp8266-ard.yaml
index 86b4d7f181..ee2c29ca4e 100644
--- a/tests/components/mcp9808/test.esp8266-ard.yaml
+++ b/tests/components/mcp9808/test.esp8266-ard.yaml
@@ -1,8 +1,5 @@
-i2c:
-  - id: i2c_mcp9808
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: mcp9808
-    name: MCP9808 Temperature
+<<: !include common.yaml
diff --git a/tests/components/mcp9808/test.rp2040-ard.yaml b/tests/components/mcp9808/test.rp2040-ard.yaml
index 86b4d7f181..ee2c29ca4e 100644
--- a/tests/components/mcp9808/test.rp2040-ard.yaml
+++ b/tests/components/mcp9808/test.rp2040-ard.yaml
@@ -1,8 +1,5 @@
-i2c:
-  - id: i2c_mcp9808
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: mcp9808
-    name: MCP9808 Temperature
+<<: !include common.yaml
diff --git a/tests/components/mhz19/common.yaml b/tests/components/mhz19/common.yaml
new file mode 100644
index 0000000000..8b7e732068
--- /dev/null
+++ b/tests/components/mhz19/common.yaml
@@ -0,0 +1,14 @@
+uart:
+  - id: uart_mhz19
+    tx_pin: ${tx_pin}
+    rx_pin: ${rx_pin}
+    baud_rate: 9600
+
+sensor:
+  - platform: mhz19
+    co2:
+      name: MH-Z19 CO2 Value
+    temperature:
+      name: MH-Z19 Temperature
+    automatic_baseline_calibration: false
+    update_interval: 15s
diff --git a/tests/components/mhz19/test.esp32-ard.yaml b/tests/components/mhz19/test.esp32-ard.yaml
index 0e30713b54..f486544afa 100644
--- a/tests/components/mhz19/test.esp32-ard.yaml
+++ b/tests/components/mhz19/test.esp32-ard.yaml
@@ -1,14 +1,5 @@
-uart:
-  - id: uart_mhz19
-    tx_pin: 17
-    rx_pin: 16
-    baud_rate: 9600
+substitutions:
+  tx_pin: GPIO17
+  rx_pin: GPIO16
 
-sensor:
-  - platform: mhz19
-    co2:
-      name: MH-Z19 CO2 Value
-    temperature:
-      name: MH-Z19 Temperature
-    automatic_baseline_calibration: false
-    update_interval: 15s
+<<: !include common.yaml
diff --git a/tests/components/mhz19/test.esp32-c3-ard.yaml b/tests/components/mhz19/test.esp32-c3-ard.yaml
index 1edfa49c23..b516342f3b 100644
--- a/tests/components/mhz19/test.esp32-c3-ard.yaml
+++ b/tests/components/mhz19/test.esp32-c3-ard.yaml
@@ -1,14 +1,5 @@
-uart:
-  - id: uart_mhz19
-    tx_pin: 4
-    rx_pin: 5
-    baud_rate: 9600
+substitutions:
+  tx_pin: GPIO4
+  rx_pin: GPIO5
 
-sensor:
-  - platform: mhz19
-    co2:
-      name: MH-Z19 CO2 Value
-    temperature:
-      name: MH-Z19 Temperature
-    automatic_baseline_calibration: false
-    update_interval: 15s
+<<: !include common.yaml
diff --git a/tests/components/mhz19/test.esp32-c3-idf.yaml b/tests/components/mhz19/test.esp32-c3-idf.yaml
index 1edfa49c23..b516342f3b 100644
--- a/tests/components/mhz19/test.esp32-c3-idf.yaml
+++ b/tests/components/mhz19/test.esp32-c3-idf.yaml
@@ -1,14 +1,5 @@
-uart:
-  - id: uart_mhz19
-    tx_pin: 4
-    rx_pin: 5
-    baud_rate: 9600
+substitutions:
+  tx_pin: GPIO4
+  rx_pin: GPIO5
 
-sensor:
-  - platform: mhz19
-    co2:
-      name: MH-Z19 CO2 Value
-    temperature:
-      name: MH-Z19 Temperature
-    automatic_baseline_calibration: false
-    update_interval: 15s
+<<: !include common.yaml
diff --git a/tests/components/mhz19/test.esp32-idf.yaml b/tests/components/mhz19/test.esp32-idf.yaml
index 0e30713b54..f486544afa 100644
--- a/tests/components/mhz19/test.esp32-idf.yaml
+++ b/tests/components/mhz19/test.esp32-idf.yaml
@@ -1,14 +1,5 @@
-uart:
-  - id: uart_mhz19
-    tx_pin: 17
-    rx_pin: 16
-    baud_rate: 9600
+substitutions:
+  tx_pin: GPIO17
+  rx_pin: GPIO16
 
-sensor:
-  - platform: mhz19
-    co2:
-      name: MH-Z19 CO2 Value
-    temperature:
-      name: MH-Z19 Temperature
-    automatic_baseline_calibration: false
-    update_interval: 15s
+<<: !include common.yaml
diff --git a/tests/components/mhz19/test.esp8266-ard.yaml b/tests/components/mhz19/test.esp8266-ard.yaml
index 1edfa49c23..b516342f3b 100644
--- a/tests/components/mhz19/test.esp8266-ard.yaml
+++ b/tests/components/mhz19/test.esp8266-ard.yaml
@@ -1,14 +1,5 @@
-uart:
-  - id: uart_mhz19
-    tx_pin: 4
-    rx_pin: 5
-    baud_rate: 9600
+substitutions:
+  tx_pin: GPIO4
+  rx_pin: GPIO5
 
-sensor:
-  - platform: mhz19
-    co2:
-      name: MH-Z19 CO2 Value
-    temperature:
-      name: MH-Z19 Temperature
-    automatic_baseline_calibration: false
-    update_interval: 15s
+<<: !include common.yaml
diff --git a/tests/components/mhz19/test.rp2040-ard.yaml b/tests/components/mhz19/test.rp2040-ard.yaml
index 1edfa49c23..b516342f3b 100644
--- a/tests/components/mhz19/test.rp2040-ard.yaml
+++ b/tests/components/mhz19/test.rp2040-ard.yaml
@@ -1,14 +1,5 @@
-uart:
-  - id: uart_mhz19
-    tx_pin: 4
-    rx_pin: 5
-    baud_rate: 9600
+substitutions:
+  tx_pin: GPIO4
+  rx_pin: GPIO5
 
-sensor:
-  - platform: mhz19
-    co2:
-      name: MH-Z19 CO2 Value
-    temperature:
-      name: MH-Z19 Temperature
-    automatic_baseline_calibration: false
-    update_interval: 15s
+<<: !include common.yaml
diff --git a/tests/components/micronova/common.yaml b/tests/components/micronova/common.yaml
new file mode 100644
index 0000000000..661c9330c6
--- /dev/null
+++ b/tests/components/micronova/common.yaml
@@ -0,0 +1,49 @@
+uart:
+  - id: uart_micronova
+    tx_pin: ${tx_pin}
+    rx_pin: ${rx_pin}
+    baud_rate: 9600
+
+micronova:
+  enable_rx_pin: ${enable_rx_pin}
+
+button:
+  - platform: micronova
+    custom_button:
+      name: Custom Micronova Button
+      memory_location: 0xA0
+      memory_address: 0x7D
+      memory_data: 0x0F
+
+number:
+  - platform: micronova
+    thermostat_temperature:
+      name: Micronova Thermostaat
+      step: 1
+    power_level:
+      name: Micronova Power level
+
+sensor:
+  - platform: micronova
+    room_temperature:
+      name: Room Temperature
+    fumes_temperature:
+      name: Fumes Temperature
+    water_temperature:
+      name: Water temperature
+    water_pressure:
+      name: Water pressure
+    stove_power:
+      name: Stove Power
+    fan_speed:
+      fan_rpm_offset: 240
+      name: Fan RPM
+    memory_address_sensor:
+      memory_location: 0x20
+      memory_address: 0x7d
+      name: Adres sensor
+
+switch:
+  - platform: micronova
+    stove:
+      name: Stove on/off
diff --git a/tests/components/micronova/test.esp32-ard.yaml b/tests/components/micronova/test.esp32-ard.yaml
index 9156f7d6a9..35d041e047 100644
--- a/tests/components/micronova/test.esp32-ard.yaml
+++ b/tests/components/micronova/test.esp32-ard.yaml
@@ -1,49 +1,6 @@
-uart:
-  - id: uart_micronova
-    tx_pin: 17
-    rx_pin: 16
-    baud_rate: 9600
+substitutions:
+  tx_pin: GPIO12
+  rx_pin: GPIO14
+  enable_rx_pin: GPIO13
 
-micronova:
-  enable_rx_pin: 18
-
-button:
-  - platform: micronova
-    custom_button:
-      name: Custom Micronova Button
-      memory_location: 0xA0
-      memory_address: 0x7D
-      memory_data: 0x0F
-
-number:
-  - platform: micronova
-    thermostat_temperature:
-      name: Micronova Thermostaat
-      step: 1
-    power_level:
-      name: Micronova Power level
-
-sensor:
-  - platform: micronova
-    room_temperature:
-      name: Room Temperature
-    fumes_temperature:
-      name: Fumes Temperature
-    water_temperature:
-      name: Water temperature
-    water_pressure:
-      name: Water pressure
-    stove_power:
-      name: Stove Power
-    fan_speed:
-      fan_rpm_offset: 240
-      name: Fan RPM
-    memory_address_sensor:
-      memory_location: 0x20
-      memory_address: 0x7d
-      name: Adres sensor
-
-switch:
-  - platform: micronova
-    stove:
-      name: Stove on/off
+<<: !include common.yaml
diff --git a/tests/components/micronova/test.esp32-c3-ard.yaml b/tests/components/micronova/test.esp32-c3-ard.yaml
index ec9699909e..993071999f 100644
--- a/tests/components/micronova/test.esp32-c3-ard.yaml
+++ b/tests/components/micronova/test.esp32-c3-ard.yaml
@@ -1,49 +1,6 @@
-uart:
-  - id: uart_micronova
-    tx_pin: 4
-    rx_pin: 5
-    baud_rate: 9600
+substitutions:
+  tx_pin: GPIO4
+  rx_pin: GPIO5
+  enable_rx_pin: GPIO3
 
-micronova:
-  enable_rx_pin: 6
-
-button:
-  - platform: micronova
-    custom_button:
-      name: Custom Micronova Button
-      memory_location: 0xA0
-      memory_address: 0x7D
-      memory_data: 0x0F
-
-number:
-  - platform: micronova
-    thermostat_temperature:
-      name: Micronova Thermostaat
-      step: 1
-    power_level:
-      name: Micronova Power level
-
-sensor:
-  - platform: micronova
-    room_temperature:
-      name: Room Temperature
-    fumes_temperature:
-      name: Fumes Temperature
-    water_temperature:
-      name: Water temperature
-    water_pressure:
-      name: Water pressure
-    stove_power:
-      name: Stove Power
-    fan_speed:
-      fan_rpm_offset: 240
-      name: Fan RPM
-    memory_address_sensor:
-      memory_location: 0x20
-      memory_address: 0x7d
-      name: Adres sensor
-
-switch:
-  - platform: micronova
-    stove:
-      name: Stove on/off
+<<: !include common.yaml
diff --git a/tests/components/micronova/test.esp32-c3-idf.yaml b/tests/components/micronova/test.esp32-c3-idf.yaml
index ec9699909e..993071999f 100644
--- a/tests/components/micronova/test.esp32-c3-idf.yaml
+++ b/tests/components/micronova/test.esp32-c3-idf.yaml
@@ -1,49 +1,6 @@
-uart:
-  - id: uart_micronova
-    tx_pin: 4
-    rx_pin: 5
-    baud_rate: 9600
+substitutions:
+  tx_pin: GPIO4
+  rx_pin: GPIO5
+  enable_rx_pin: GPIO3
 
-micronova:
-  enable_rx_pin: 6
-
-button:
-  - platform: micronova
-    custom_button:
-      name: Custom Micronova Button
-      memory_location: 0xA0
-      memory_address: 0x7D
-      memory_data: 0x0F
-
-number:
-  - platform: micronova
-    thermostat_temperature:
-      name: Micronova Thermostaat
-      step: 1
-    power_level:
-      name: Micronova Power level
-
-sensor:
-  - platform: micronova
-    room_temperature:
-      name: Room Temperature
-    fumes_temperature:
-      name: Fumes Temperature
-    water_temperature:
-      name: Water temperature
-    water_pressure:
-      name: Water pressure
-    stove_power:
-      name: Stove Power
-    fan_speed:
-      fan_rpm_offset: 240
-      name: Fan RPM
-    memory_address_sensor:
-      memory_location: 0x20
-      memory_address: 0x7d
-      name: Adres sensor
-
-switch:
-  - platform: micronova
-    stove:
-      name: Stove on/off
+<<: !include common.yaml
diff --git a/tests/components/micronova/test.esp32-idf.yaml b/tests/components/micronova/test.esp32-idf.yaml
index 9156f7d6a9..35d041e047 100644
--- a/tests/components/micronova/test.esp32-idf.yaml
+++ b/tests/components/micronova/test.esp32-idf.yaml
@@ -1,49 +1,6 @@
-uart:
-  - id: uart_micronova
-    tx_pin: 17
-    rx_pin: 16
-    baud_rate: 9600
+substitutions:
+  tx_pin: GPIO12
+  rx_pin: GPIO14
+  enable_rx_pin: GPIO13
 
-micronova:
-  enable_rx_pin: 18
-
-button:
-  - platform: micronova
-    custom_button:
-      name: Custom Micronova Button
-      memory_location: 0xA0
-      memory_address: 0x7D
-      memory_data: 0x0F
-
-number:
-  - platform: micronova
-    thermostat_temperature:
-      name: Micronova Thermostaat
-      step: 1
-    power_level:
-      name: Micronova Power level
-
-sensor:
-  - platform: micronova
-    room_temperature:
-      name: Room Temperature
-    fumes_temperature:
-      name: Fumes Temperature
-    water_temperature:
-      name: Water temperature
-    water_pressure:
-      name: Water pressure
-    stove_power:
-      name: Stove Power
-    fan_speed:
-      fan_rpm_offset: 240
-      name: Fan RPM
-    memory_address_sensor:
-      memory_location: 0x20
-      memory_address: 0x7d
-      name: Adres sensor
-
-switch:
-  - platform: micronova
-    stove:
-      name: Stove on/off
+<<: !include common.yaml
diff --git a/tests/components/micronova/test.esp8266-ard.yaml b/tests/components/micronova/test.esp8266-ard.yaml
index d10ab7ad7a..048fb82d72 100644
--- a/tests/components/micronova/test.esp8266-ard.yaml
+++ b/tests/components/micronova/test.esp8266-ard.yaml
@@ -1,49 +1,6 @@
-uart:
-  - id: uart_micronova
-    tx_pin: 4
-    rx_pin: 5
-    baud_rate: 9600
+substitutions:
+  tx_pin: GPIO4
+  rx_pin: GPIO5
+  enable_rx_pin: GPIO13
 
-micronova:
-  enable_rx_pin: 16
-
-button:
-  - platform: micronova
-    custom_button:
-      name: Custom Micronova Button
-      memory_location: 0xA0
-      memory_address: 0x7D
-      memory_data: 0x0F
-
-number:
-  - platform: micronova
-    thermostat_temperature:
-      name: Micronova Thermostaat
-      step: 1
-    power_level:
-      name: Micronova Power level
-
-sensor:
-  - platform: micronova
-    room_temperature:
-      name: Room Temperature
-    fumes_temperature:
-      name: Fumes Temperature
-    water_temperature:
-      name: Water temperature
-    water_pressure:
-      name: Water pressure
-    stove_power:
-      name: Stove Power
-    fan_speed:
-      fan_rpm_offset: 240
-      name: Fan RPM
-    memory_address_sensor:
-      memory_location: 0x20
-      memory_address: 0x7d
-      name: Adres sensor
-
-switch:
-  - platform: micronova
-    stove:
-      name: Stove on/off
+<<: !include common.yaml
diff --git a/tests/components/micronova/test.rp2040-ard.yaml b/tests/components/micronova/test.rp2040-ard.yaml
index ec9699909e..993071999f 100644
--- a/tests/components/micronova/test.rp2040-ard.yaml
+++ b/tests/components/micronova/test.rp2040-ard.yaml
@@ -1,49 +1,6 @@
-uart:
-  - id: uart_micronova
-    tx_pin: 4
-    rx_pin: 5
-    baud_rate: 9600
+substitutions:
+  tx_pin: GPIO4
+  rx_pin: GPIO5
+  enable_rx_pin: GPIO3
 
-micronova:
-  enable_rx_pin: 6
-
-button:
-  - platform: micronova
-    custom_button:
-      name: Custom Micronova Button
-      memory_location: 0xA0
-      memory_address: 0x7D
-      memory_data: 0x0F
-
-number:
-  - platform: micronova
-    thermostat_temperature:
-      name: Micronova Thermostaat
-      step: 1
-    power_level:
-      name: Micronova Power level
-
-sensor:
-  - platform: micronova
-    room_temperature:
-      name: Room Temperature
-    fumes_temperature:
-      name: Fumes Temperature
-    water_temperature:
-      name: Water temperature
-    water_pressure:
-      name: Water pressure
-    stove_power:
-      name: Stove Power
-    fan_speed:
-      fan_rpm_offset: 240
-      name: Fan RPM
-    memory_address_sensor:
-      memory_location: 0x20
-      memory_address: 0x7d
-      name: Adres sensor
-
-switch:
-  - platform: micronova
-    stove:
-      name: Stove on/off
+<<: !include common.yaml
diff --git a/tests/components/microphone/common.yaml b/tests/components/microphone/common.yaml
new file mode 100644
index 0000000000..ea79266281
--- /dev/null
+++ b/tests/components/microphone/common.yaml
@@ -0,0 +1,11 @@
+i2s_audio:
+  i2s_bclk_pin: ${i2s_bclk_pin}
+  i2s_lrclk_pin: ${i2s_lrclk_pin}
+  i2s_mclk_pin: ${i2s_mclk_pin}
+
+microphone:
+  - platform: i2s_audio
+    id: mic_id_external
+    i2s_din_pin: ${i2s_din_pin}
+    adc_type: external
+    pdm: false
diff --git a/tests/components/microphone/test.esp32-ard.yaml b/tests/components/microphone/test.esp32-ard.yaml
index 166eedb54d..392df582cc 100644
--- a/tests/components/microphone/test.esp32-ard.yaml
+++ b/tests/components/microphone/test.esp32-ard.yaml
@@ -1,15 +1,13 @@
-i2s_audio:
-  i2s_lrclk_pin: 13
-  i2s_bclk_pin: 14
-  i2s_mclk_pin: 15
+substitutions:
+  i2s_bclk_pin: GPIO15
+  i2s_lrclk_pin: GPIO16
+  i2s_mclk_pin: GPIO17
+  i2s_din_pin: GPIO33
+
+<<: !include common.yaml
 
 microphone:
   - platform: i2s_audio
     id: mic_id_adc
     adc_pin: 32
     adc_type: internal
-  - platform: i2s_audio
-    id: mic_id_external
-    i2s_din_pin: 33
-    adc_type: external
-    pdm: false
diff --git a/tests/components/microphone/test.esp32-c3-ard.yaml b/tests/components/microphone/test.esp32-c3-ard.yaml
index 706a38f910..c28dc553f5 100644
--- a/tests/components/microphone/test.esp32-c3-ard.yaml
+++ b/tests/components/microphone/test.esp32-c3-ard.yaml
@@ -1,11 +1,7 @@
-i2s_audio:
-  i2s_lrclk_pin: 6
-  i2s_bclk_pin: 7
-  i2s_mclk_pin: 8
+substitutions:
+  i2s_bclk_pin: GPIO6
+  i2s_lrclk_pin: GPIO7
+  i2s_mclk_pin: GPIO8
+  i2s_din_pin: GPIO3
 
-microphone:
-  - platform: i2s_audio
-    id: mic_id_external
-    i2s_din_pin: 3
-    adc_type: external
-    pdm: false
+<<: !include common.yaml
diff --git a/tests/components/microphone/test.esp32-c3-idf.yaml b/tests/components/microphone/test.esp32-c3-idf.yaml
index 706a38f910..c28dc553f5 100644
--- a/tests/components/microphone/test.esp32-c3-idf.yaml
+++ b/tests/components/microphone/test.esp32-c3-idf.yaml
@@ -1,11 +1,7 @@
-i2s_audio:
-  i2s_lrclk_pin: 6
-  i2s_bclk_pin: 7
-  i2s_mclk_pin: 8
+substitutions:
+  i2s_bclk_pin: GPIO6
+  i2s_lrclk_pin: GPIO7
+  i2s_mclk_pin: GPIO8
+  i2s_din_pin: GPIO3
 
-microphone:
-  - platform: i2s_audio
-    id: mic_id_external
-    i2s_din_pin: 3
-    adc_type: external
-    pdm: false
+<<: !include common.yaml
diff --git a/tests/components/microphone/test.esp32-idf.yaml b/tests/components/microphone/test.esp32-idf.yaml
index 166eedb54d..392df582cc 100644
--- a/tests/components/microphone/test.esp32-idf.yaml
+++ b/tests/components/microphone/test.esp32-idf.yaml
@@ -1,15 +1,13 @@
-i2s_audio:
-  i2s_lrclk_pin: 13
-  i2s_bclk_pin: 14
-  i2s_mclk_pin: 15
+substitutions:
+  i2s_bclk_pin: GPIO15
+  i2s_lrclk_pin: GPIO16
+  i2s_mclk_pin: GPIO17
+  i2s_din_pin: GPIO33
+
+<<: !include common.yaml
 
 microphone:
   - platform: i2s_audio
     id: mic_id_adc
     adc_pin: 32
     adc_type: internal
-  - platform: i2s_audio
-    id: mic_id_external
-    i2s_din_pin: 33
-    adc_type: external
-    pdm: false
diff --git a/tests/components/mics_4514/common.yaml b/tests/components/mics_4514/common.yaml
new file mode 100644
index 0000000000..0bc3f3e654
--- /dev/null
+++ b/tests/components/mics_4514/common.yaml
@@ -0,0 +1,20 @@
+i2c:
+  - id: i2c_mics_4514
+    scl: ${scl_pin}
+    sda: ${sda_pin}
+
+sensor:
+  - platform: mics_4514
+    update_interval: 60s
+    nitrogen_dioxide:
+      name: MICS-4514 NO2
+    carbon_monoxide:
+      name: MICS-4514 CO
+    methane:
+      name: MICS-4514 CH4
+    hydrogen:
+      name: MICS-4514 H2
+    ethanol:
+      name: MICS-4514 C2H5OH
+    ammonia:
+      name: MICS-4514 NH3
diff --git a/tests/components/mics_4514/test.esp32-ard.yaml b/tests/components/mics_4514/test.esp32-ard.yaml
index 234839c91c..63c3bd6afd 100644
--- a/tests/components/mics_4514/test.esp32-ard.yaml
+++ b/tests/components/mics_4514/test.esp32-ard.yaml
@@ -1,20 +1,5 @@
-i2c:
-  - id: i2c_mics_4514
-    scl: 16
-    sda: 17
+substitutions:
+  scl_pin: GPIO16
+  sda_pin: GPIO17
 
-sensor:
-  - platform: mics_4514
-    update_interval: 60s
-    nitrogen_dioxide:
-      name: MICS-4514 NO2
-    carbon_monoxide:
-      name: MICS-4514 CO
-    methane:
-      name: MICS-4514 CH4
-    hydrogen:
-      name: MICS-4514 H2
-    ethanol:
-      name: MICS-4514 C2H5OH
-    ammonia:
-      name: MICS-4514 NH3
+<<: !include common.yaml
diff --git a/tests/components/mics_4514/test.esp32-c3-ard.yaml b/tests/components/mics_4514/test.esp32-c3-ard.yaml
index 72369bec01..ee2c29ca4e 100644
--- a/tests/components/mics_4514/test.esp32-c3-ard.yaml
+++ b/tests/components/mics_4514/test.esp32-c3-ard.yaml
@@ -1,20 +1,5 @@
-i2c:
-  - id: i2c_mics_4514
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: mics_4514
-    update_interval: 60s
-    nitrogen_dioxide:
-      name: MICS-4514 NO2
-    carbon_monoxide:
-      name: MICS-4514 CO
-    methane:
-      name: MICS-4514 CH4
-    hydrogen:
-      name: MICS-4514 H2
-    ethanol:
-      name: MICS-4514 C2H5OH
-    ammonia:
-      name: MICS-4514 NH3
+<<: !include common.yaml
diff --git a/tests/components/mics_4514/test.esp32-c3-idf.yaml b/tests/components/mics_4514/test.esp32-c3-idf.yaml
index 72369bec01..ee2c29ca4e 100644
--- a/tests/components/mics_4514/test.esp32-c3-idf.yaml
+++ b/tests/components/mics_4514/test.esp32-c3-idf.yaml
@@ -1,20 +1,5 @@
-i2c:
-  - id: i2c_mics_4514
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: mics_4514
-    update_interval: 60s
-    nitrogen_dioxide:
-      name: MICS-4514 NO2
-    carbon_monoxide:
-      name: MICS-4514 CO
-    methane:
-      name: MICS-4514 CH4
-    hydrogen:
-      name: MICS-4514 H2
-    ethanol:
-      name: MICS-4514 C2H5OH
-    ammonia:
-      name: MICS-4514 NH3
+<<: !include common.yaml
diff --git a/tests/components/mics_4514/test.esp32-idf.yaml b/tests/components/mics_4514/test.esp32-idf.yaml
index 234839c91c..63c3bd6afd 100644
--- a/tests/components/mics_4514/test.esp32-idf.yaml
+++ b/tests/components/mics_4514/test.esp32-idf.yaml
@@ -1,20 +1,5 @@
-i2c:
-  - id: i2c_mics_4514
-    scl: 16
-    sda: 17
+substitutions:
+  scl_pin: GPIO16
+  sda_pin: GPIO17
 
-sensor:
-  - platform: mics_4514
-    update_interval: 60s
-    nitrogen_dioxide:
-      name: MICS-4514 NO2
-    carbon_monoxide:
-      name: MICS-4514 CO
-    methane:
-      name: MICS-4514 CH4
-    hydrogen:
-      name: MICS-4514 H2
-    ethanol:
-      name: MICS-4514 C2H5OH
-    ammonia:
-      name: MICS-4514 NH3
+<<: !include common.yaml
diff --git a/tests/components/mics_4514/test.esp8266-ard.yaml b/tests/components/mics_4514/test.esp8266-ard.yaml
index 72369bec01..ee2c29ca4e 100644
--- a/tests/components/mics_4514/test.esp8266-ard.yaml
+++ b/tests/components/mics_4514/test.esp8266-ard.yaml
@@ -1,20 +1,5 @@
-i2c:
-  - id: i2c_mics_4514
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: mics_4514
-    update_interval: 60s
-    nitrogen_dioxide:
-      name: MICS-4514 NO2
-    carbon_monoxide:
-      name: MICS-4514 CO
-    methane:
-      name: MICS-4514 CH4
-    hydrogen:
-      name: MICS-4514 H2
-    ethanol:
-      name: MICS-4514 C2H5OH
-    ammonia:
-      name: MICS-4514 NH3
+<<: !include common.yaml
diff --git a/tests/components/mics_4514/test.rp2040-ard.yaml b/tests/components/mics_4514/test.rp2040-ard.yaml
index 72369bec01..ee2c29ca4e 100644
--- a/tests/components/mics_4514/test.rp2040-ard.yaml
+++ b/tests/components/mics_4514/test.rp2040-ard.yaml
@@ -1,20 +1,5 @@
-i2c:
-  - id: i2c_mics_4514
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: mics_4514
-    update_interval: 60s
-    nitrogen_dioxide:
-      name: MICS-4514 NO2
-    carbon_monoxide:
-      name: MICS-4514 CO
-    methane:
-      name: MICS-4514 CH4
-    hydrogen:
-      name: MICS-4514 H2
-    ethanol:
-      name: MICS-4514 C2H5OH
-    ammonia:
-      name: MICS-4514 NH3
+<<: !include common.yaml
diff --git a/tests/components/midea/common.yaml b/tests/components/midea/common.yaml
new file mode 100644
index 0000000000..07385e29a1
--- /dev/null
+++ b/tests/components/midea/common.yaml
@@ -0,0 +1,59 @@
+wifi:
+  ssid: MySSID
+  password: password1
+
+remote_transmitter:
+  pin: ${pin}
+  carrier_duty_percent: 50%
+
+uart:
+  - id: uart_midea
+    tx_pin: ${tx_pin}
+    rx_pin: ${rx_pin}
+    baud_rate: 9600
+
+climate:
+  - platform: midea
+    id: midea_unit
+    name: Midea Climate
+    on_control:
+      - logger.log: Control message received!
+      - lambda: |-
+          x.set_mode(CLIMATE_MODE_FAN_ONLY);
+    on_state:
+      - logger.log: State changed!
+    transmitter_id:
+    period: 1s
+    num_attempts: 5
+    timeout: 2s
+    beeper: false
+    autoconf: true
+    visual:
+      min_temperature: 17 °C
+      max_temperature: 30 °C
+      temperature_step: 0.5 °C
+    supported_modes:
+      - FAN_ONLY
+      - HEAT_COOL
+      - COOL
+      - HEAT
+      - DRY
+    custom_fan_modes:
+      - SILENT
+      - TURBO
+    supported_presets:
+      - ECO
+      - BOOST
+      - SLEEP
+    custom_presets:
+      - FREEZE_PROTECTION
+    supported_swing_modes:
+      - VERTICAL
+      - HORIZONTAL
+      - BOTH
+    outdoor_temperature:
+      name: Temp
+    power_usage:
+      name: Power
+    humidity_setpoint:
+      name: Humidity
diff --git a/tests/components/midea/test.esp32-ard.yaml b/tests/components/midea/test.esp32-ard.yaml
index 5c638b9613..7f55d6a52d 100644
--- a/tests/components/midea/test.esp32-ard.yaml
+++ b/tests/components/midea/test.esp32-ard.yaml
@@ -1,59 +1,6 @@
-wifi:
-  ssid: MySSID
-  password: password1
+substitutions:
+  tx_pin: GPIO12
+  rx_pin: GPIO14
+  pin: GPIO2
 
-remote_transmitter:
-  pin: 18
-  carrier_duty_percent: 50%
-
-uart:
-  - id: uart_midea
-    tx_pin: 17
-    rx_pin: 16
-    baud_rate: 9600
-
-climate:
-  - platform: midea
-    id: midea_unit
-    name: Midea Climate
-    on_control:
-      - logger.log: Control message received!
-      - lambda: |-
-          x.set_mode(CLIMATE_MODE_FAN_ONLY);
-    on_state:
-      - logger.log: State changed!
-    transmitter_id:
-    period: 1s
-    num_attempts: 5
-    timeout: 2s
-    beeper: false
-    autoconf: true
-    visual:
-      min_temperature: 17 °C
-      max_temperature: 30 °C
-      temperature_step: 0.5 °C
-    supported_modes:
-      - FAN_ONLY
-      - HEAT_COOL
-      - COOL
-      - HEAT
-      - DRY
-    custom_fan_modes:
-      - SILENT
-      - TURBO
-    supported_presets:
-      - ECO
-      - BOOST
-      - SLEEP
-    custom_presets:
-      - FREEZE_PROTECTION
-    supported_swing_modes:
-      - VERTICAL
-      - HORIZONTAL
-      - BOTH
-    outdoor_temperature:
-      name: Temp
-    power_usage:
-      name: Power
-    humidity_setpoint:
-      name: Humidity
+<<: !include common.yaml
diff --git a/tests/components/midea/test.esp32-c3-ard.yaml b/tests/components/midea/test.esp32-c3-ard.yaml
index bcb8635eaf..a879df3ca4 100644
--- a/tests/components/midea/test.esp32-c3-ard.yaml
+++ b/tests/components/midea/test.esp32-c3-ard.yaml
@@ -1,59 +1,6 @@
-wifi:
-  ssid: MySSID
-  password: password1
+substitutions:
+  tx_pin: GPIO4
+  rx_pin: GPIO5
+  pin: GPIO2
 
-remote_transmitter:
-  pin: 2
-  carrier_duty_percent: 50%
-
-uart:
-  - id: uart_midea
-    tx_pin: 4
-    rx_pin: 5
-    baud_rate: 9600
-
-climate:
-  - platform: midea
-    id: midea_unit
-    name: Midea Climate
-    on_control:
-      - logger.log: Control message received!
-      - lambda: |-
-          x.set_mode(CLIMATE_MODE_FAN_ONLY);
-    on_state:
-      - logger.log: State changed!
-    transmitter_id:
-    period: 1s
-    num_attempts: 5
-    timeout: 2s
-    beeper: false
-    autoconf: true
-    visual:
-      min_temperature: 17 °C
-      max_temperature: 30 °C
-      temperature_step: 0.5 °C
-    supported_modes:
-      - FAN_ONLY
-      - HEAT_COOL
-      - COOL
-      - HEAT
-      - DRY
-    custom_fan_modes:
-      - SILENT
-      - TURBO
-    supported_presets:
-      - ECO
-      - BOOST
-      - SLEEP
-    custom_presets:
-      - FREEZE_PROTECTION
-    supported_swing_modes:
-      - VERTICAL
-      - HORIZONTAL
-      - BOTH
-    outdoor_temperature:
-      name: Temp
-    power_usage:
-      name: Power
-    humidity_setpoint:
-      name: Humidity
+<<: !include common.yaml
diff --git a/tests/components/midea/test.esp8266-ard.yaml b/tests/components/midea/test.esp8266-ard.yaml
index b0ed7eb472..4f50bd7e5e 100644
--- a/tests/components/midea/test.esp8266-ard.yaml
+++ b/tests/components/midea/test.esp8266-ard.yaml
@@ -1,59 +1,6 @@
-wifi:
-  ssid: MySSID
-  password: password1
+substitutions:
+  tx_pin: GPIO4
+  rx_pin: GPIO5
+  pin: GPIO15
 
-remote_transmitter:
-  pin: 12
-  carrier_duty_percent: 50%
-
-uart:
-  - id: uart_midea
-    tx_pin: 4
-    rx_pin: 5
-    baud_rate: 9600
-
-climate:
-  - platform: midea
-    id: midea_unit
-    name: Midea Climate
-    on_control:
-      - logger.log: Control message received!
-      - lambda: |-
-          x.set_mode(CLIMATE_MODE_FAN_ONLY);
-    on_state:
-      - logger.log: State changed!
-    transmitter_id:
-    period: 1s
-    num_attempts: 5
-    timeout: 2s
-    beeper: false
-    autoconf: true
-    visual:
-      min_temperature: 17 °C
-      max_temperature: 30 °C
-      temperature_step: 0.5 °C
-    supported_modes:
-      - FAN_ONLY
-      - HEAT_COOL
-      - COOL
-      - HEAT
-      - DRY
-    custom_fan_modes:
-      - SILENT
-      - TURBO
-    supported_presets:
-      - ECO
-      - BOOST
-      - SLEEP
-    custom_presets:
-      - FREEZE_PROTECTION
-    supported_swing_modes:
-      - VERTICAL
-      - HORIZONTAL
-      - BOTH
-    outdoor_temperature:
-      name: Temp
-    power_usage:
-      name: Power
-    humidity_setpoint:
-      name: Humidity
+<<: !include common.yaml
diff --git a/tests/components/mlx90393/common.yaml b/tests/components/mlx90393/common.yaml
new file mode 100644
index 0000000000..a7ab0867cc
--- /dev/null
+++ b/tests/components/mlx90393/common.yaml
@@ -0,0 +1,20 @@
+i2c:
+  - id: i2c_mlx90393
+    scl: ${scl_pin}
+    sda: ${sda_pin}
+
+sensor:
+  - platform: mlx90393
+    oversampling: 1
+    filter: 0
+    gain: 3X
+    x_axis:
+      name: mlxxaxis
+    y_axis:
+      name: mlxyaxis
+    z_axis:
+      name: mlxzaxis
+      resolution: 17BIT
+    temperature:
+      name: mlxtemp
+      oversampling: 2
diff --git a/tests/components/mlx90393/test.esp32-ard.yaml b/tests/components/mlx90393/test.esp32-ard.yaml
index 089fd136f4..63c3bd6afd 100644
--- a/tests/components/mlx90393/test.esp32-ard.yaml
+++ b/tests/components/mlx90393/test.esp32-ard.yaml
@@ -1,20 +1,5 @@
-i2c:
-  - id: i2c_mlx90393
-    scl: 16
-    sda: 17
+substitutions:
+  scl_pin: GPIO16
+  sda_pin: GPIO17
 
-sensor:
-  - platform: mlx90393
-    oversampling: 1
-    filter: 0
-    gain: 3X
-    x_axis:
-      name: mlxxaxis
-    y_axis:
-      name: mlxyaxis
-    z_axis:
-      name: mlxzaxis
-      resolution: 17BIT
-    temperature:
-      name: mlxtemp
-      oversampling: 2
+<<: !include common.yaml
diff --git a/tests/components/mlx90393/test.esp32-c3-ard.yaml b/tests/components/mlx90393/test.esp32-c3-ard.yaml
index 549eea8032..ee2c29ca4e 100644
--- a/tests/components/mlx90393/test.esp32-c3-ard.yaml
+++ b/tests/components/mlx90393/test.esp32-c3-ard.yaml
@@ -1,20 +1,5 @@
-i2c:
-  - id: i2c_mlx90393
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: mlx90393
-    oversampling: 1
-    filter: 0
-    gain: 3X
-    x_axis:
-      name: mlxxaxis
-    y_axis:
-      name: mlxyaxis
-    z_axis:
-      name: mlxzaxis
-      resolution: 17BIT
-    temperature:
-      name: mlxtemp
-      oversampling: 2
+<<: !include common.yaml
diff --git a/tests/components/mlx90393/test.esp32-c3-idf.yaml b/tests/components/mlx90393/test.esp32-c3-idf.yaml
index 549eea8032..ee2c29ca4e 100644
--- a/tests/components/mlx90393/test.esp32-c3-idf.yaml
+++ b/tests/components/mlx90393/test.esp32-c3-idf.yaml
@@ -1,20 +1,5 @@
-i2c:
-  - id: i2c_mlx90393
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: mlx90393
-    oversampling: 1
-    filter: 0
-    gain: 3X
-    x_axis:
-      name: mlxxaxis
-    y_axis:
-      name: mlxyaxis
-    z_axis:
-      name: mlxzaxis
-      resolution: 17BIT
-    temperature:
-      name: mlxtemp
-      oversampling: 2
+<<: !include common.yaml
diff --git a/tests/components/mlx90393/test.esp32-idf.yaml b/tests/components/mlx90393/test.esp32-idf.yaml
index 089fd136f4..63c3bd6afd 100644
--- a/tests/components/mlx90393/test.esp32-idf.yaml
+++ b/tests/components/mlx90393/test.esp32-idf.yaml
@@ -1,20 +1,5 @@
-i2c:
-  - id: i2c_mlx90393
-    scl: 16
-    sda: 17
+substitutions:
+  scl_pin: GPIO16
+  sda_pin: GPIO17
 
-sensor:
-  - platform: mlx90393
-    oversampling: 1
-    filter: 0
-    gain: 3X
-    x_axis:
-      name: mlxxaxis
-    y_axis:
-      name: mlxyaxis
-    z_axis:
-      name: mlxzaxis
-      resolution: 17BIT
-    temperature:
-      name: mlxtemp
-      oversampling: 2
+<<: !include common.yaml
diff --git a/tests/components/mlx90393/test.esp8266-ard.yaml b/tests/components/mlx90393/test.esp8266-ard.yaml
index 549eea8032..ee2c29ca4e 100644
--- a/tests/components/mlx90393/test.esp8266-ard.yaml
+++ b/tests/components/mlx90393/test.esp8266-ard.yaml
@@ -1,20 +1,5 @@
-i2c:
-  - id: i2c_mlx90393
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: mlx90393
-    oversampling: 1
-    filter: 0
-    gain: 3X
-    x_axis:
-      name: mlxxaxis
-    y_axis:
-      name: mlxyaxis
-    z_axis:
-      name: mlxzaxis
-      resolution: 17BIT
-    temperature:
-      name: mlxtemp
-      oversampling: 2
+<<: !include common.yaml
diff --git a/tests/components/mlx90393/test.rp2040-ard.yaml b/tests/components/mlx90393/test.rp2040-ard.yaml
index 549eea8032..ee2c29ca4e 100644
--- a/tests/components/mlx90393/test.rp2040-ard.yaml
+++ b/tests/components/mlx90393/test.rp2040-ard.yaml
@@ -1,20 +1,5 @@
-i2c:
-  - id: i2c_mlx90393
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: mlx90393
-    oversampling: 1
-    filter: 0
-    gain: 3X
-    x_axis:
-      name: mlxxaxis
-    y_axis:
-      name: mlxyaxis
-    z_axis:
-      name: mlxzaxis
-      resolution: 17BIT
-    temperature:
-      name: mlxtemp
-      oversampling: 2
+<<: !include common.yaml
diff --git a/tests/components/mlx90614/common.yaml b/tests/components/mlx90614/common.yaml
new file mode 100644
index 0000000000..03279e6e14
--- /dev/null
+++ b/tests/components/mlx90614/common.yaml
@@ -0,0 +1,12 @@
+i2c:
+  - id: i2c_mlx90614
+    scl: ${scl_pin}
+    sda: ${sda_pin}
+
+sensor:
+  - platform: mlx90614
+    ambient:
+      name: Ambient
+    object:
+      name: Object
+      emissivity: 1.0
diff --git a/tests/components/mlx90614/test.esp32-ard.yaml b/tests/components/mlx90614/test.esp32-ard.yaml
index 8c1ee68f42..63c3bd6afd 100644
--- a/tests/components/mlx90614/test.esp32-ard.yaml
+++ b/tests/components/mlx90614/test.esp32-ard.yaml
@@ -1,12 +1,5 @@
-i2c:
-  - id: i2c_mlx90614
-    scl: 16
-    sda: 17
+substitutions:
+  scl_pin: GPIO16
+  sda_pin: GPIO17
 
-sensor:
-  - platform: mlx90614
-    ambient:
-      name: Ambient
-    object:
-      name: Object
-      emissivity: 1.0
+<<: !include common.yaml
diff --git a/tests/components/mlx90614/test.esp32-c3-ard.yaml b/tests/components/mlx90614/test.esp32-c3-ard.yaml
index a863e0ee2e..ee2c29ca4e 100644
--- a/tests/components/mlx90614/test.esp32-c3-ard.yaml
+++ b/tests/components/mlx90614/test.esp32-c3-ard.yaml
@@ -1,12 +1,5 @@
-i2c:
-  - id: i2c_mlx90614
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: mlx90614
-    ambient:
-      name: Ambient
-    object:
-      name: Object
-      emissivity: 1.0
+<<: !include common.yaml
diff --git a/tests/components/mlx90614/test.esp32-c3-idf.yaml b/tests/components/mlx90614/test.esp32-c3-idf.yaml
index a863e0ee2e..ee2c29ca4e 100644
--- a/tests/components/mlx90614/test.esp32-c3-idf.yaml
+++ b/tests/components/mlx90614/test.esp32-c3-idf.yaml
@@ -1,12 +1,5 @@
-i2c:
-  - id: i2c_mlx90614
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: mlx90614
-    ambient:
-      name: Ambient
-    object:
-      name: Object
-      emissivity: 1.0
+<<: !include common.yaml
diff --git a/tests/components/mlx90614/test.esp32-idf.yaml b/tests/components/mlx90614/test.esp32-idf.yaml
index 8c1ee68f42..63c3bd6afd 100644
--- a/tests/components/mlx90614/test.esp32-idf.yaml
+++ b/tests/components/mlx90614/test.esp32-idf.yaml
@@ -1,12 +1,5 @@
-i2c:
-  - id: i2c_mlx90614
-    scl: 16
-    sda: 17
+substitutions:
+  scl_pin: GPIO16
+  sda_pin: GPIO17
 
-sensor:
-  - platform: mlx90614
-    ambient:
-      name: Ambient
-    object:
-      name: Object
-      emissivity: 1.0
+<<: !include common.yaml
diff --git a/tests/components/mlx90614/test.esp8266-ard.yaml b/tests/components/mlx90614/test.esp8266-ard.yaml
index a863e0ee2e..ee2c29ca4e 100644
--- a/tests/components/mlx90614/test.esp8266-ard.yaml
+++ b/tests/components/mlx90614/test.esp8266-ard.yaml
@@ -1,12 +1,5 @@
-i2c:
-  - id: i2c_mlx90614
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: mlx90614
-    ambient:
-      name: Ambient
-    object:
-      name: Object
-      emissivity: 1.0
+<<: !include common.yaml
diff --git a/tests/components/mlx90614/test.rp2040-ard.yaml b/tests/components/mlx90614/test.rp2040-ard.yaml
index a863e0ee2e..ee2c29ca4e 100644
--- a/tests/components/mlx90614/test.rp2040-ard.yaml
+++ b/tests/components/mlx90614/test.rp2040-ard.yaml
@@ -1,12 +1,5 @@
-i2c:
-  - id: i2c_mlx90614
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: mlx90614
-    ambient:
-      name: Ambient
-    object:
-      name: Object
-      emissivity: 1.0
+<<: !include common.yaml
diff --git a/tests/components/mmc5603/common.yaml b/tests/components/mmc5603/common.yaml
new file mode 100644
index 0000000000..83235f596e
--- /dev/null
+++ b/tests/components/mmc5603/common.yaml
@@ -0,0 +1,14 @@
+i2c:
+  - id: i2c_mmc5603
+    scl: ${scl_pin}
+    sda: ${sda_pin}
+
+sensor:
+  - platform: mmc5603
+    address: 0x30
+    field_strength_x:
+      name: HMC5883L Field Strength X
+    field_strength_y:
+      name: HMC5883L Field Strength Y
+    field_strength_z:
+      name: HMC5883L Field Strength Z
diff --git a/tests/components/mmc5603/test.esp32-ard.yaml b/tests/components/mmc5603/test.esp32-ard.yaml
index fbb83cd9f8..63c3bd6afd 100644
--- a/tests/components/mmc5603/test.esp32-ard.yaml
+++ b/tests/components/mmc5603/test.esp32-ard.yaml
@@ -1,14 +1,5 @@
-i2c:
-  - id: i2c_mmc5603
-    scl: 16
-    sda: 17
+substitutions:
+  scl_pin: GPIO16
+  sda_pin: GPIO17
 
-sensor:
-  - platform: mmc5603
-    address: 0x30
-    field_strength_x:
-      name: HMC5883L Field Strength X
-    field_strength_y:
-      name: HMC5883L Field Strength Y
-    field_strength_z:
-      name: HMC5883L Field Strength Z
+<<: !include common.yaml
diff --git a/tests/components/mmc5603/test.esp32-c3-ard.yaml b/tests/components/mmc5603/test.esp32-c3-ard.yaml
index 834591bb39..ee2c29ca4e 100644
--- a/tests/components/mmc5603/test.esp32-c3-ard.yaml
+++ b/tests/components/mmc5603/test.esp32-c3-ard.yaml
@@ -1,14 +1,5 @@
-i2c:
-  - id: i2c_mmc5603
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: mmc5603
-    address: 0x30
-    field_strength_x:
-      name: HMC5883L Field Strength X
-    field_strength_y:
-      name: HMC5883L Field Strength Y
-    field_strength_z:
-      name: HMC5883L Field Strength Z
+<<: !include common.yaml
diff --git a/tests/components/mmc5603/test.esp32-c3-idf.yaml b/tests/components/mmc5603/test.esp32-c3-idf.yaml
index 834591bb39..ee2c29ca4e 100644
--- a/tests/components/mmc5603/test.esp32-c3-idf.yaml
+++ b/tests/components/mmc5603/test.esp32-c3-idf.yaml
@@ -1,14 +1,5 @@
-i2c:
-  - id: i2c_mmc5603
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: mmc5603
-    address: 0x30
-    field_strength_x:
-      name: HMC5883L Field Strength X
-    field_strength_y:
-      name: HMC5883L Field Strength Y
-    field_strength_z:
-      name: HMC5883L Field Strength Z
+<<: !include common.yaml
diff --git a/tests/components/mmc5603/test.esp32-idf.yaml b/tests/components/mmc5603/test.esp32-idf.yaml
index fbb83cd9f8..63c3bd6afd 100644
--- a/tests/components/mmc5603/test.esp32-idf.yaml
+++ b/tests/components/mmc5603/test.esp32-idf.yaml
@@ -1,14 +1,5 @@
-i2c:
-  - id: i2c_mmc5603
-    scl: 16
-    sda: 17
+substitutions:
+  scl_pin: GPIO16
+  sda_pin: GPIO17
 
-sensor:
-  - platform: mmc5603
-    address: 0x30
-    field_strength_x:
-      name: HMC5883L Field Strength X
-    field_strength_y:
-      name: HMC5883L Field Strength Y
-    field_strength_z:
-      name: HMC5883L Field Strength Z
+<<: !include common.yaml
diff --git a/tests/components/mmc5603/test.esp8266-ard.yaml b/tests/components/mmc5603/test.esp8266-ard.yaml
index 834591bb39..ee2c29ca4e 100644
--- a/tests/components/mmc5603/test.esp8266-ard.yaml
+++ b/tests/components/mmc5603/test.esp8266-ard.yaml
@@ -1,14 +1,5 @@
-i2c:
-  - id: i2c_mmc5603
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: mmc5603
-    address: 0x30
-    field_strength_x:
-      name: HMC5883L Field Strength X
-    field_strength_y:
-      name: HMC5883L Field Strength Y
-    field_strength_z:
-      name: HMC5883L Field Strength Z
+<<: !include common.yaml
diff --git a/tests/components/mmc5603/test.rp2040-ard.yaml b/tests/components/mmc5603/test.rp2040-ard.yaml
index 834591bb39..ee2c29ca4e 100644
--- a/tests/components/mmc5603/test.rp2040-ard.yaml
+++ b/tests/components/mmc5603/test.rp2040-ard.yaml
@@ -1,14 +1,5 @@
-i2c:
-  - id: i2c_mmc5603
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: mmc5603
-    address: 0x30
-    field_strength_x:
-      name: HMC5883L Field Strength X
-    field_strength_y:
-      name: HMC5883L Field Strength Y
-    field_strength_z:
-      name: HMC5883L Field Strength Z
+<<: !include common.yaml
diff --git a/tests/components/mmc5983/common.yaml b/tests/components/mmc5983/common.yaml
new file mode 100644
index 0000000000..949ff527e7
--- /dev/null
+++ b/tests/components/mmc5983/common.yaml
@@ -0,0 +1,16 @@
+i2c:
+  - id: i2c_mmc5983
+    scl: ${scl_pin}
+    sda: ${sda_pin}
+
+sensor:
+  - platform: mmc5983
+    field_strength_x:
+      name: "Magnet X"
+      id: magnet_x
+    field_strength_y:
+      name: "Magnet Y"
+      id: magnet_y
+    field_strength_z:
+      name: "Magnet Z"
+      id: magnet_z
diff --git a/tests/components/mmc5983/test.esp32-ard.yaml b/tests/components/mmc5983/test.esp32-ard.yaml
index 6104be9b83..63c3bd6afd 100644
--- a/tests/components/mmc5983/test.esp32-ard.yaml
+++ b/tests/components/mmc5983/test.esp32-ard.yaml
@@ -1,16 +1,5 @@
-i2c:
-  - id: i2c_mmc5983
-    scl: 16
-    sda: 17
+substitutions:
+  scl_pin: GPIO16
+  sda_pin: GPIO17
 
-sensor:
-  - platform: mmc5983
-    field_strength_x:
-      name: "Magnet X"
-      id: magnet_x
-    field_strength_y:
-      name: "Magnet Y"
-      id: magnet_y
-    field_strength_z:
-      name: "Magnet Z"
-      id: magnet_z
+<<: !include common.yaml
diff --git a/tests/components/mmc5983/test.esp32-c3-ard.yaml b/tests/components/mmc5983/test.esp32-c3-ard.yaml
index 68d821e9a5..ee2c29ca4e 100644
--- a/tests/components/mmc5983/test.esp32-c3-ard.yaml
+++ b/tests/components/mmc5983/test.esp32-c3-ard.yaml
@@ -1,16 +1,5 @@
-i2c:
-  - id: i2c_mmc5983
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: mmc5983
-    field_strength_x:
-      name: "Magnet X"
-      id: magnet_x
-    field_strength_y:
-      name: "Magnet Y"
-      id: magnet_y
-    field_strength_z:
-      name: "Magnet Z"
-      id: magnet_z
+<<: !include common.yaml
diff --git a/tests/components/mmc5983/test.esp32-c3-idf.yaml b/tests/components/mmc5983/test.esp32-c3-idf.yaml
index 68d821e9a5..ee2c29ca4e 100644
--- a/tests/components/mmc5983/test.esp32-c3-idf.yaml
+++ b/tests/components/mmc5983/test.esp32-c3-idf.yaml
@@ -1,16 +1,5 @@
-i2c:
-  - id: i2c_mmc5983
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: mmc5983
-    field_strength_x:
-      name: "Magnet X"
-      id: magnet_x
-    field_strength_y:
-      name: "Magnet Y"
-      id: magnet_y
-    field_strength_z:
-      name: "Magnet Z"
-      id: magnet_z
+<<: !include common.yaml
diff --git a/tests/components/mmc5983/test.esp32-idf.yaml b/tests/components/mmc5983/test.esp32-idf.yaml
index 6104be9b83..63c3bd6afd 100644
--- a/tests/components/mmc5983/test.esp32-idf.yaml
+++ b/tests/components/mmc5983/test.esp32-idf.yaml
@@ -1,16 +1,5 @@
-i2c:
-  - id: i2c_mmc5983
-    scl: 16
-    sda: 17
+substitutions:
+  scl_pin: GPIO16
+  sda_pin: GPIO17
 
-sensor:
-  - platform: mmc5983
-    field_strength_x:
-      name: "Magnet X"
-      id: magnet_x
-    field_strength_y:
-      name: "Magnet Y"
-      id: magnet_y
-    field_strength_z:
-      name: "Magnet Z"
-      id: magnet_z
+<<: !include common.yaml
diff --git a/tests/components/mmc5983/test.esp8266-ard.yaml b/tests/components/mmc5983/test.esp8266-ard.yaml
index 68d821e9a5..ee2c29ca4e 100644
--- a/tests/components/mmc5983/test.esp8266-ard.yaml
+++ b/tests/components/mmc5983/test.esp8266-ard.yaml
@@ -1,16 +1,5 @@
-i2c:
-  - id: i2c_mmc5983
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: mmc5983
-    field_strength_x:
-      name: "Magnet X"
-      id: magnet_x
-    field_strength_y:
-      name: "Magnet Y"
-      id: magnet_y
-    field_strength_z:
-      name: "Magnet Z"
-      id: magnet_z
+<<: !include common.yaml
diff --git a/tests/components/mmc5983/test.rp2040-ard.yaml b/tests/components/mmc5983/test.rp2040-ard.yaml
index 68d821e9a5..ee2c29ca4e 100644
--- a/tests/components/mmc5983/test.rp2040-ard.yaml
+++ b/tests/components/mmc5983/test.rp2040-ard.yaml
@@ -1,16 +1,5 @@
-i2c:
-  - id: i2c_mmc5983
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: mmc5983
-    field_strength_x:
-      name: "Magnet X"
-      id: magnet_x
-    field_strength_y:
-      name: "Magnet Y"
-      id: magnet_y
-    field_strength_z:
-      name: "Magnet Z"
-      id: magnet_z
+<<: !include common.yaml
diff --git a/tests/components/modbus/common.yaml b/tests/components/modbus/common.yaml
new file mode 100644
index 0000000000..3ec9518585
--- /dev/null
+++ b/tests/components/modbus/common.yaml
@@ -0,0 +1,9 @@
+uart:
+  - id: uart_modbus
+    tx_pin: ${tx_pin}
+    rx_pin: ${rx_pin}
+    baud_rate: 9600
+
+modbus:
+  id: mod_bus1
+  flow_control_pin: ${flow_control_pin}
diff --git a/tests/components/modbus/test.esp32-ard.yaml b/tests/components/modbus/test.esp32-ard.yaml
index 20cf238b1b..bd767a8ece 100644
--- a/tests/components/modbus/test.esp32-ard.yaml
+++ b/tests/components/modbus/test.esp32-ard.yaml
@@ -1,9 +1,6 @@
-uart:
-  - id: uart_modbus
-    tx_pin: 17
-    rx_pin: 16
-    baud_rate: 9600
+substitutions:
+  tx_pin: GPIO12
+  rx_pin: GPIO14
+  flow_control_pin: GPIO13
 
-modbus:
-  id: mod_bus1
-  flow_control_pin: 15
+<<: !include common.yaml
diff --git a/tests/components/modbus/test.esp32-c3-ard.yaml b/tests/components/modbus/test.esp32-c3-ard.yaml
index d22b507be0..452031a5aa 100644
--- a/tests/components/modbus/test.esp32-c3-ard.yaml
+++ b/tests/components/modbus/test.esp32-c3-ard.yaml
@@ -1,9 +1,6 @@
-uart:
-  - id: uart_modbus
-    tx_pin: 4
-    rx_pin: 5
-    baud_rate: 9600
+substitutions:
+  tx_pin: GPIO4
+  rx_pin: GPIO5
+  flow_control_pin: GPIO3
 
-modbus:
-  id: mod_bus1
-  flow_control_pin: 6
+<<: !include common.yaml
diff --git a/tests/components/modbus/test.esp32-c3-idf.yaml b/tests/components/modbus/test.esp32-c3-idf.yaml
index d22b507be0..452031a5aa 100644
--- a/tests/components/modbus/test.esp32-c3-idf.yaml
+++ b/tests/components/modbus/test.esp32-c3-idf.yaml
@@ -1,9 +1,6 @@
-uart:
-  - id: uart_modbus
-    tx_pin: 4
-    rx_pin: 5
-    baud_rate: 9600
+substitutions:
+  tx_pin: GPIO4
+  rx_pin: GPIO5
+  flow_control_pin: GPIO3
 
-modbus:
-  id: mod_bus1
-  flow_control_pin: 6
+<<: !include common.yaml
diff --git a/tests/components/modbus/test.esp32-idf.yaml b/tests/components/modbus/test.esp32-idf.yaml
index 20cf238b1b..bd767a8ece 100644
--- a/tests/components/modbus/test.esp32-idf.yaml
+++ b/tests/components/modbus/test.esp32-idf.yaml
@@ -1,9 +1,6 @@
-uart:
-  - id: uart_modbus
-    tx_pin: 17
-    rx_pin: 16
-    baud_rate: 9600
+substitutions:
+  tx_pin: GPIO12
+  rx_pin: GPIO14
+  flow_control_pin: GPIO13
 
-modbus:
-  id: mod_bus1
-  flow_control_pin: 15
+<<: !include common.yaml
diff --git a/tests/components/modbus/test.esp8266-ard.yaml b/tests/components/modbus/test.esp8266-ard.yaml
index 560c044766..29c98d0957 100644
--- a/tests/components/modbus/test.esp8266-ard.yaml
+++ b/tests/components/modbus/test.esp8266-ard.yaml
@@ -1,9 +1,6 @@
-uart:
-  - id: uart_modbus
-    tx_pin: 4
-    rx_pin: 5
-    baud_rate: 9600
+substitutions:
+  tx_pin: GPIO4
+  rx_pin: GPIO5
+  flow_control_pin: GPIO13
 
-modbus:
-  id: mod_bus1
-  flow_control_pin: 12
+<<: !include common.yaml
diff --git a/tests/components/modbus/test.rp2040-ard.yaml b/tests/components/modbus/test.rp2040-ard.yaml
index d22b507be0..452031a5aa 100644
--- a/tests/components/modbus/test.rp2040-ard.yaml
+++ b/tests/components/modbus/test.rp2040-ard.yaml
@@ -1,9 +1,6 @@
-uart:
-  - id: uart_modbus
-    tx_pin: 4
-    rx_pin: 5
-    baud_rate: 9600
+substitutions:
+  tx_pin: GPIO4
+  rx_pin: GPIO5
+  flow_control_pin: GPIO3
 
-modbus:
-  id: mod_bus1
-  flow_control_pin: 6
+<<: !include common.yaml
diff --git a/tests/components/modbus_controller/common.yaml b/tests/components/modbus_controller/common.yaml
new file mode 100644
index 0000000000..93d8391ff5
--- /dev/null
+++ b/tests/components/modbus_controller/common.yaml
@@ -0,0 +1,35 @@
+uart:
+  - id: uart_modbus_client
+    tx_pin: ${client_tx_pin}
+    rx_pin: ${client_rx_pin}
+    baud_rate: 9600
+  - id: uart_modbus_server
+    tx_pin: ${server_tx_pin}
+    rx_pin: ${server_rx_pin}
+    baud_rate: 9600
+
+modbus:
+  - id: mod_bus1
+    uart_id: uart_modbus_client
+    flow_control_pin: ${flow_control_pin}
+  - id: mod_bus2
+    uart_id: uart_modbus_server
+    role: server
+
+modbus_controller:
+  - id: modbus_controller1
+    address: 0x2
+    modbus_id: mod_bus1
+    allow_duplicate_commands: false
+    on_online:
+      then:
+        logger.log: "Module Online"
+  - id: modbus_controller2
+    address: 0x2
+    modbus_id: mod_bus2
+    server_registers:
+      - address: 0x0000
+        value_type: S_DWORD_R
+        read_lambda: |-
+          return 42.3;
+    max_cmd_retries: 0
diff --git a/tests/components/modbus_controller/test.esp32-ard.yaml b/tests/components/modbus_controller/test.esp32-ard.yaml
index f5c5c10125..548b8c0666 100644
--- a/tests/components/modbus_controller/test.esp32-ard.yaml
+++ b/tests/components/modbus_controller/test.esp32-ard.yaml
@@ -1,35 +1,8 @@
-uart:
-  - id: uart_modbus_client
-    tx_pin: 17
-    rx_pin: 16
-    baud_rate: 9600
-  - id: uart_modbus_server
-    tx_pin: 1
-    rx_pin: 3
-    baud_rate: 9600
+substitutions:
+  client_tx_pin: GPIO12
+  client_rx_pin: GPIO14
+  server_tx_pin: GPIO16
+  server_rx_pin: GPIO17
+  flow_control_pin: GPIO13
 
-modbus:
-  - id: mod_bus1
-    uart_id: uart_modbus_client
-    flow_control_pin: 15
-  - id: mod_bus2
-    uart_id: uart_modbus_server
-    role: server
-
-modbus_controller:
-  - id: modbus_controller1
-    address: 0x2
-    modbus_id: mod_bus1
-    allow_duplicate_commands: false
-    on_online:
-      then:
-        logger.log: "Module Online"
-  - id: modbus_controller2
-    address: 0x2
-    modbus_id: mod_bus2
-    server_registers:
-      - address: 0x0000
-        value_type: S_DWORD_R
-        read_lambda: |-
-          return 42.3;
-    max_cmd_retries: 0
+<<: !include common.yaml
diff --git a/tests/components/modbus_controller/test.esp32-c3-ard.yaml b/tests/components/modbus_controller/test.esp32-c3-ard.yaml
index 476e65ecb0..f5b770ff58 100644
--- a/tests/components/modbus_controller/test.esp32-c3-ard.yaml
+++ b/tests/components/modbus_controller/test.esp32-c3-ard.yaml
@@ -1,14 +1,8 @@
-uart:
-  - id: uart_modbus
-    tx_pin: 4
-    rx_pin: 5
-    baud_rate: 9600
+substitutions:
+  client_tx_pin: GPIO4
+  client_rx_pin: GPIO5
+  server_tx_pin: GPIO6
+  server_rx_pin: GPIO7
+  flow_control_pin: GPIO3
 
-modbus:
-  id: mod_bus1
-  flow_control_pin: 6
-
-modbus_controller:
-  - id: modbus_controller1
-    address: 0x2
-    modbus_id: mod_bus1
+<<: !include common.yaml
diff --git a/tests/components/modbus_controller/test.esp32-c3-idf.yaml b/tests/components/modbus_controller/test.esp32-c3-idf.yaml
index 476e65ecb0..f5b770ff58 100644
--- a/tests/components/modbus_controller/test.esp32-c3-idf.yaml
+++ b/tests/components/modbus_controller/test.esp32-c3-idf.yaml
@@ -1,14 +1,8 @@
-uart:
-  - id: uart_modbus
-    tx_pin: 4
-    rx_pin: 5
-    baud_rate: 9600
+substitutions:
+  client_tx_pin: GPIO4
+  client_rx_pin: GPIO5
+  server_tx_pin: GPIO6
+  server_rx_pin: GPIO7
+  flow_control_pin: GPIO3
 
-modbus:
-  id: mod_bus1
-  flow_control_pin: 6
-
-modbus_controller:
-  - id: modbus_controller1
-    address: 0x2
-    modbus_id: mod_bus1
+<<: !include common.yaml
diff --git a/tests/components/modbus_controller/test.esp32-idf.yaml b/tests/components/modbus_controller/test.esp32-idf.yaml
index 0e1849dd88..548b8c0666 100644
--- a/tests/components/modbus_controller/test.esp32-idf.yaml
+++ b/tests/components/modbus_controller/test.esp32-idf.yaml
@@ -1,19 +1,8 @@
-uart:
-  - id: uart_modbus
-    tx_pin: 17
-    rx_pin: 16
-    baud_rate: 9600
+substitutions:
+  client_tx_pin: GPIO12
+  client_rx_pin: GPIO14
+  server_tx_pin: GPIO16
+  server_rx_pin: GPIO17
+  flow_control_pin: GPIO13
 
-modbus:
-  id: mod_bus1
-  flow_control_pin: 15
-
-modbus_controller:
-  - id: modbus_controller1
-    address: 0x2
-    modbus_id: mod_bus1
-    allow_duplicate_commands: true
-    on_offline:
-      then:
-        logger.log: "Module Offline"
-    max_cmd_retries: 10
+<<: !include common.yaml
diff --git a/tests/components/modbus_controller/test.esp8266-ard.yaml b/tests/components/modbus_controller/test.esp8266-ard.yaml
index 67cac65d1b..c68a57cbde 100644
--- a/tests/components/modbus_controller/test.esp8266-ard.yaml
+++ b/tests/components/modbus_controller/test.esp8266-ard.yaml
@@ -1,14 +1,8 @@
-uart:
-  - id: uart_modbus
-    tx_pin: 4
-    rx_pin: 5
-    baud_rate: 9600
+substitutions:
+  client_tx_pin: GPIO1
+  client_rx_pin: GPIO3
+  server_tx_pin: GPIO4
+  server_rx_pin: GPIO5
+  flow_control_pin: GPIO13
 
-modbus:
-  id: mod_bus1
-  flow_control_pin: 12
-
-modbus_controller:
-  - id: modbus_controller1
-    address: 0x2
-    modbus_id: mod_bus1
+<<: !include common.yaml
diff --git a/tests/components/modbus_controller/test.rp2040-ard.yaml b/tests/components/modbus_controller/test.rp2040-ard.yaml
index 476e65ecb0..80528bc12b 100644
--- a/tests/components/modbus_controller/test.rp2040-ard.yaml
+++ b/tests/components/modbus_controller/test.rp2040-ard.yaml
@@ -1,14 +1,8 @@
-uart:
-  - id: uart_modbus
-    tx_pin: 4
-    rx_pin: 5
-    baud_rate: 9600
+substitutions:
+  client_tx_pin: GPIO2
+  client_rx_pin: GPIO3
+  server_tx_pin: GPIO4
+  server_rx_pin: GPIO5
+  flow_control_pin: GPIO6
 
-modbus:
-  id: mod_bus1
-  flow_control_pin: 6
-
-modbus_controller:
-  - id: modbus_controller1
-    address: 0x2
-    modbus_id: mod_bus1
+<<: !include common.yaml
diff --git a/tests/components/monochromatic/common.yaml b/tests/components/monochromatic/common.yaml
new file mode 100644
index 0000000000..9915e086eb
--- /dev/null
+++ b/tests/components/monochromatic/common.yaml
@@ -0,0 +1,40 @@
+output:
+  - platform: ${light_platform}
+    id: light_output_1
+    pin: ${pin}
+
+light:
+  - platform: monochromatic
+    name: Monochromatic Light
+    id: monochromatic_light
+    output: light_output_1
+    gamma_correct: 2.8
+    default_transition_length: 2s
+    effects:
+      - strobe:
+      - flicker:
+      - flicker:
+          name: My Flicker
+          alpha: 98%
+          intensity: 1.5%
+      - lambda:
+          name: My Custom Effect
+          update_interval: 1s
+          lambda: |-
+            static int state = 0;
+            state += 1;
+            if (state == 4)
+              state = 0;
+      - pulse:
+          transition_length: 10s
+          update_interval: 20s
+          min_brightness: 10%
+          max_brightness: 90%
+      - pulse:
+          name: pulse2
+          transition_length:
+            on_length: 10s
+            off_length: 5s
+          update_interval: 15s
+          min_brightness: 10%
+          max_brightness: 90%
diff --git a/tests/components/monochromatic/test.esp32-ard.yaml b/tests/components/monochromatic/test.esp32-ard.yaml
index 9524efcb2d..feabf013fd 100644
--- a/tests/components/monochromatic/test.esp32-ard.yaml
+++ b/tests/components/monochromatic/test.esp32-ard.yaml
@@ -1,40 +1,5 @@
-output:
-  - platform: ledc
-    id: light_output_1
-    pin: 4
+substitutions:
+  light_platform: ledc
+  pin: GPIO2
 
-light:
-  - platform: monochromatic
-    name: Monochromatic Light
-    id: monochromatic_light
-    output: light_output_1
-    gamma_correct: 2.8
-    default_transition_length: 2s
-    effects:
-      - strobe:
-      - flicker:
-      - flicker:
-          name: My Flicker
-          alpha: 98%
-          intensity: 1.5%
-      - lambda:
-          name: My Custom Effect
-          update_interval: 1s
-          lambda: |-
-            static int state = 0;
-            state += 1;
-            if (state == 4)
-              state = 0;
-      - pulse:
-          transition_length: 10s
-          update_interval: 20s
-          min_brightness: 10%
-          max_brightness: 90%
-      - pulse:
-          name: pulse2
-          transition_length:
-            on_length: 10s
-            off_length: 5s
-          update_interval: 15s
-          min_brightness: 10%
-          max_brightness: 90%
+<<: !include common.yaml
diff --git a/tests/components/monochromatic/test.esp32-c3-ard.yaml b/tests/components/monochromatic/test.esp32-c3-ard.yaml
index 9524efcb2d..feabf013fd 100644
--- a/tests/components/monochromatic/test.esp32-c3-ard.yaml
+++ b/tests/components/monochromatic/test.esp32-c3-ard.yaml
@@ -1,40 +1,5 @@
-output:
-  - platform: ledc
-    id: light_output_1
-    pin: 4
+substitutions:
+  light_platform: ledc
+  pin: GPIO2
 
-light:
-  - platform: monochromatic
-    name: Monochromatic Light
-    id: monochromatic_light
-    output: light_output_1
-    gamma_correct: 2.8
-    default_transition_length: 2s
-    effects:
-      - strobe:
-      - flicker:
-      - flicker:
-          name: My Flicker
-          alpha: 98%
-          intensity: 1.5%
-      - lambda:
-          name: My Custom Effect
-          update_interval: 1s
-          lambda: |-
-            static int state = 0;
-            state += 1;
-            if (state == 4)
-              state = 0;
-      - pulse:
-          transition_length: 10s
-          update_interval: 20s
-          min_brightness: 10%
-          max_brightness: 90%
-      - pulse:
-          name: pulse2
-          transition_length:
-            on_length: 10s
-            off_length: 5s
-          update_interval: 15s
-          min_brightness: 10%
-          max_brightness: 90%
+<<: !include common.yaml
diff --git a/tests/components/monochromatic/test.esp32-c3-idf.yaml b/tests/components/monochromatic/test.esp32-c3-idf.yaml
index 9524efcb2d..feabf013fd 100644
--- a/tests/components/monochromatic/test.esp32-c3-idf.yaml
+++ b/tests/components/monochromatic/test.esp32-c3-idf.yaml
@@ -1,40 +1,5 @@
-output:
-  - platform: ledc
-    id: light_output_1
-    pin: 4
+substitutions:
+  light_platform: ledc
+  pin: GPIO2
 
-light:
-  - platform: monochromatic
-    name: Monochromatic Light
-    id: monochromatic_light
-    output: light_output_1
-    gamma_correct: 2.8
-    default_transition_length: 2s
-    effects:
-      - strobe:
-      - flicker:
-      - flicker:
-          name: My Flicker
-          alpha: 98%
-          intensity: 1.5%
-      - lambda:
-          name: My Custom Effect
-          update_interval: 1s
-          lambda: |-
-            static int state = 0;
-            state += 1;
-            if (state == 4)
-              state = 0;
-      - pulse:
-          transition_length: 10s
-          update_interval: 20s
-          min_brightness: 10%
-          max_brightness: 90%
-      - pulse:
-          name: pulse2
-          transition_length:
-            on_length: 10s
-            off_length: 5s
-          update_interval: 15s
-          min_brightness: 10%
-          max_brightness: 90%
+<<: !include common.yaml
diff --git a/tests/components/monochromatic/test.esp32-idf.yaml b/tests/components/monochromatic/test.esp32-idf.yaml
index 9524efcb2d..feabf013fd 100644
--- a/tests/components/monochromatic/test.esp32-idf.yaml
+++ b/tests/components/monochromatic/test.esp32-idf.yaml
@@ -1,40 +1,5 @@
-output:
-  - platform: ledc
-    id: light_output_1
-    pin: 4
+substitutions:
+  light_platform: ledc
+  pin: GPIO2
 
-light:
-  - platform: monochromatic
-    name: Monochromatic Light
-    id: monochromatic_light
-    output: light_output_1
-    gamma_correct: 2.8
-    default_transition_length: 2s
-    effects:
-      - strobe:
-      - flicker:
-      - flicker:
-          name: My Flicker
-          alpha: 98%
-          intensity: 1.5%
-      - lambda:
-          name: My Custom Effect
-          update_interval: 1s
-          lambda: |-
-            static int state = 0;
-            state += 1;
-            if (state == 4)
-              state = 0;
-      - pulse:
-          transition_length: 10s
-          update_interval: 20s
-          min_brightness: 10%
-          max_brightness: 90%
-      - pulse:
-          name: pulse2
-          transition_length:
-            on_length: 10s
-            off_length: 5s
-          update_interval: 15s
-          min_brightness: 10%
-          max_brightness: 90%
+<<: !include common.yaml
diff --git a/tests/components/monochromatic/test.esp8266-ard.yaml b/tests/components/monochromatic/test.esp8266-ard.yaml
index 94d849581d..65bfb329f1 100644
--- a/tests/components/monochromatic/test.esp8266-ard.yaml
+++ b/tests/components/monochromatic/test.esp8266-ard.yaml
@@ -1,40 +1,5 @@
-output:
-  - platform: esp8266_pwm
-    id: light_output_1
-    pin: 4
+substitutions:
+  light_platform: esp8266_pwm
+  pin: GPIO5
 
-light:
-  - platform: monochromatic
-    name: Monochromatic Light
-    id: monochromatic_light
-    output: light_output_1
-    gamma_correct: 2.8
-    default_transition_length: 2s
-    effects:
-      - strobe:
-      - flicker:
-      - flicker:
-          name: My Flicker
-          alpha: 98%
-          intensity: 1.5%
-      - lambda:
-          name: My Custom Effect
-          update_interval: 1s
-          lambda: |-
-            static int state = 0;
-            state += 1;
-            if (state == 4)
-              state = 0;
-      - pulse:
-          transition_length: 10s
-          update_interval: 20s
-          min_brightness: 10%
-          max_brightness: 90%
-      - pulse:
-          name: pulse2
-          transition_length:
-            on_length: 10s
-            off_length: 5s
-          update_interval: 15s
-          min_brightness: 10%
-          max_brightness: 90%
+<<: !include common.yaml
diff --git a/tests/components/monochromatic/test.rp2040-ard.yaml b/tests/components/monochromatic/test.rp2040-ard.yaml
index 093577e256..d329597d46 100644
--- a/tests/components/monochromatic/test.rp2040-ard.yaml
+++ b/tests/components/monochromatic/test.rp2040-ard.yaml
@@ -1,40 +1,5 @@
-output:
-  - platform: rp2040_pwm
-    id: light_output_1
-    pin: 4
+substitutions:
+  light_platform: rp2040_pwm
+  pin: GPIO2
 
-light:
-  - platform: monochromatic
-    name: Monochromatic Light
-    id: monochromatic_light
-    output: light_output_1
-    gamma_correct: 2.8
-    default_transition_length: 2s
-    effects:
-      - strobe:
-      - flicker:
-      - flicker:
-          name: My Flicker
-          alpha: 98%
-          intensity: 1.5%
-      - lambda:
-          name: My Custom Effect
-          update_interval: 1s
-          lambda: |-
-            static int state = 0;
-            state += 1;
-            if (state == 4)
-              state = 0;
-      - pulse:
-          transition_length: 10s
-          update_interval: 20s
-          min_brightness: 10%
-          max_brightness: 90%
-      - pulse:
-          name: pulse2
-          transition_length:
-            on_length: 10s
-            off_length: 5s
-          update_interval: 15s
-          min_brightness: 10%
-          max_brightness: 90%
+<<: !include common.yaml
diff --git a/tests/components/mpl3115a2/common.yaml b/tests/components/mpl3115a2/common.yaml
new file mode 100644
index 0000000000..f2f65885b3
--- /dev/null
+++ b/tests/components/mpl3115a2/common.yaml
@@ -0,0 +1,12 @@
+i2c:
+  - id: i2c_mpl3115a2
+    scl: ${scl_pin}
+    sda: ${sda_pin}
+
+sensor:
+  - platform: mpl3115a2
+    temperature:
+      name: MPL3115A2 Temperature
+    pressure:
+      name: MPL3115A2 Pressure
+    update_interval: 10s
diff --git a/tests/components/mpl3115a2/test.esp32-ard.yaml b/tests/components/mpl3115a2/test.esp32-ard.yaml
index 5e9d6d190d..63c3bd6afd 100644
--- a/tests/components/mpl3115a2/test.esp32-ard.yaml
+++ b/tests/components/mpl3115a2/test.esp32-ard.yaml
@@ -1,12 +1,5 @@
-i2c:
-  - id: i2c_mpl3115a2
-    scl: 16
-    sda: 17
+substitutions:
+  scl_pin: GPIO16
+  sda_pin: GPIO17
 
-sensor:
-  - platform: mpl3115a2
-    temperature:
-      name: MPL3115A2 Temperature
-    pressure:
-      name: MPL3115A2 Pressure
-    update_interval: 10s
+<<: !include common.yaml
diff --git a/tests/components/mpl3115a2/test.esp32-c3-ard.yaml b/tests/components/mpl3115a2/test.esp32-c3-ard.yaml
index 9cbe08d920..ee2c29ca4e 100644
--- a/tests/components/mpl3115a2/test.esp32-c3-ard.yaml
+++ b/tests/components/mpl3115a2/test.esp32-c3-ard.yaml
@@ -1,12 +1,5 @@
-i2c:
-  - id: i2c_mpl3115a2
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: mpl3115a2
-    temperature:
-      name: MPL3115A2 Temperature
-    pressure:
-      name: MPL3115A2 Pressure
-    update_interval: 10s
+<<: !include common.yaml
diff --git a/tests/components/mpl3115a2/test.esp32-c3-idf.yaml b/tests/components/mpl3115a2/test.esp32-c3-idf.yaml
index 9cbe08d920..ee2c29ca4e 100644
--- a/tests/components/mpl3115a2/test.esp32-c3-idf.yaml
+++ b/tests/components/mpl3115a2/test.esp32-c3-idf.yaml
@@ -1,12 +1,5 @@
-i2c:
-  - id: i2c_mpl3115a2
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: mpl3115a2
-    temperature:
-      name: MPL3115A2 Temperature
-    pressure:
-      name: MPL3115A2 Pressure
-    update_interval: 10s
+<<: !include common.yaml
diff --git a/tests/components/mpl3115a2/test.esp32-idf.yaml b/tests/components/mpl3115a2/test.esp32-idf.yaml
index 5e9d6d190d..63c3bd6afd 100644
--- a/tests/components/mpl3115a2/test.esp32-idf.yaml
+++ b/tests/components/mpl3115a2/test.esp32-idf.yaml
@@ -1,12 +1,5 @@
-i2c:
-  - id: i2c_mpl3115a2
-    scl: 16
-    sda: 17
+substitutions:
+  scl_pin: GPIO16
+  sda_pin: GPIO17
 
-sensor:
-  - platform: mpl3115a2
-    temperature:
-      name: MPL3115A2 Temperature
-    pressure:
-      name: MPL3115A2 Pressure
-    update_interval: 10s
+<<: !include common.yaml
diff --git a/tests/components/mpl3115a2/test.esp8266-ard.yaml b/tests/components/mpl3115a2/test.esp8266-ard.yaml
index 9cbe08d920..ee2c29ca4e 100644
--- a/tests/components/mpl3115a2/test.esp8266-ard.yaml
+++ b/tests/components/mpl3115a2/test.esp8266-ard.yaml
@@ -1,12 +1,5 @@
-i2c:
-  - id: i2c_mpl3115a2
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: mpl3115a2
-    temperature:
-      name: MPL3115A2 Temperature
-    pressure:
-      name: MPL3115A2 Pressure
-    update_interval: 10s
+<<: !include common.yaml
diff --git a/tests/components/mpl3115a2/test.rp2040-ard.yaml b/tests/components/mpl3115a2/test.rp2040-ard.yaml
index 9cbe08d920..ee2c29ca4e 100644
--- a/tests/components/mpl3115a2/test.rp2040-ard.yaml
+++ b/tests/components/mpl3115a2/test.rp2040-ard.yaml
@@ -1,12 +1,5 @@
-i2c:
-  - id: i2c_mpl3115a2
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: mpl3115a2
-    temperature:
-      name: MPL3115A2 Temperature
-    pressure:
-      name: MPL3115A2 Pressure
-    update_interval: 10s
+<<: !include common.yaml
diff --git a/tests/components/mpu6050/common.yaml b/tests/components/mpu6050/common.yaml
new file mode 100644
index 0000000000..e9d4995534
--- /dev/null
+++ b/tests/components/mpu6050/common.yaml
@@ -0,0 +1,22 @@
+i2c:
+  - id: i2c_mpu6050
+    scl: ${scl_pin}
+    sda: ${sda_pin}
+
+sensor:
+  - platform: mpu6050
+    address: 0x68
+    accel_x:
+      name: MPU6050 Accel X
+    accel_y:
+      name: MPU6050 Accel Y
+    accel_z:
+      name: MPU6050 Accel z
+    gyro_x:
+      name: MPU6050 Gyro X
+    gyro_y:
+      name: MPU6050 Gyro Y
+    gyro_z:
+      name: MPU6050 Gyro z
+    temperature:
+      name: MPU6050 Temperature
diff --git a/tests/components/mpu6050/test.esp32-ard.yaml b/tests/components/mpu6050/test.esp32-ard.yaml
index 45bca55dea..63c3bd6afd 100644
--- a/tests/components/mpu6050/test.esp32-ard.yaml
+++ b/tests/components/mpu6050/test.esp32-ard.yaml
@@ -1,22 +1,5 @@
-i2c:
-  - id: i2c_mpu6050
-    scl: 16
-    sda: 17
+substitutions:
+  scl_pin: GPIO16
+  sda_pin: GPIO17
 
-sensor:
-  - platform: mpu6050
-    address: 0x68
-    accel_x:
-      name: MPU6050 Accel X
-    accel_y:
-      name: MPU6050 Accel Y
-    accel_z:
-      name: MPU6050 Accel z
-    gyro_x:
-      name: MPU6050 Gyro X
-    gyro_y:
-      name: MPU6050 Gyro Y
-    gyro_z:
-      name: MPU6050 Gyro z
-    temperature:
-      name: MPU6050 Temperature
+<<: !include common.yaml
diff --git a/tests/components/mpu6050/test.esp32-c3-ard.yaml b/tests/components/mpu6050/test.esp32-c3-ard.yaml
index 39c8506d2b..ee2c29ca4e 100644
--- a/tests/components/mpu6050/test.esp32-c3-ard.yaml
+++ b/tests/components/mpu6050/test.esp32-c3-ard.yaml
@@ -1,22 +1,5 @@
-i2c:
-  - id: i2c_mpu6050
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: mpu6050
-    address: 0x68
-    accel_x:
-      name: MPU6050 Accel X
-    accel_y:
-      name: MPU6050 Accel Y
-    accel_z:
-      name: MPU6050 Accel z
-    gyro_x:
-      name: MPU6050 Gyro X
-    gyro_y:
-      name: MPU6050 Gyro Y
-    gyro_z:
-      name: MPU6050 Gyro z
-    temperature:
-      name: MPU6050 Temperature
+<<: !include common.yaml
diff --git a/tests/components/mpu6050/test.esp32-c3-idf.yaml b/tests/components/mpu6050/test.esp32-c3-idf.yaml
index 39c8506d2b..ee2c29ca4e 100644
--- a/tests/components/mpu6050/test.esp32-c3-idf.yaml
+++ b/tests/components/mpu6050/test.esp32-c3-idf.yaml
@@ -1,22 +1,5 @@
-i2c:
-  - id: i2c_mpu6050
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: mpu6050
-    address: 0x68
-    accel_x:
-      name: MPU6050 Accel X
-    accel_y:
-      name: MPU6050 Accel Y
-    accel_z:
-      name: MPU6050 Accel z
-    gyro_x:
-      name: MPU6050 Gyro X
-    gyro_y:
-      name: MPU6050 Gyro Y
-    gyro_z:
-      name: MPU6050 Gyro z
-    temperature:
-      name: MPU6050 Temperature
+<<: !include common.yaml
diff --git a/tests/components/mpu6050/test.esp32-idf.yaml b/tests/components/mpu6050/test.esp32-idf.yaml
index 45bca55dea..63c3bd6afd 100644
--- a/tests/components/mpu6050/test.esp32-idf.yaml
+++ b/tests/components/mpu6050/test.esp32-idf.yaml
@@ -1,22 +1,5 @@
-i2c:
-  - id: i2c_mpu6050
-    scl: 16
-    sda: 17
+substitutions:
+  scl_pin: GPIO16
+  sda_pin: GPIO17
 
-sensor:
-  - platform: mpu6050
-    address: 0x68
-    accel_x:
-      name: MPU6050 Accel X
-    accel_y:
-      name: MPU6050 Accel Y
-    accel_z:
-      name: MPU6050 Accel z
-    gyro_x:
-      name: MPU6050 Gyro X
-    gyro_y:
-      name: MPU6050 Gyro Y
-    gyro_z:
-      name: MPU6050 Gyro z
-    temperature:
-      name: MPU6050 Temperature
+<<: !include common.yaml
diff --git a/tests/components/mpu6050/test.esp8266-ard.yaml b/tests/components/mpu6050/test.esp8266-ard.yaml
index 39c8506d2b..ee2c29ca4e 100644
--- a/tests/components/mpu6050/test.esp8266-ard.yaml
+++ b/tests/components/mpu6050/test.esp8266-ard.yaml
@@ -1,22 +1,5 @@
-i2c:
-  - id: i2c_mpu6050
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: mpu6050
-    address: 0x68
-    accel_x:
-      name: MPU6050 Accel X
-    accel_y:
-      name: MPU6050 Accel Y
-    accel_z:
-      name: MPU6050 Accel z
-    gyro_x:
-      name: MPU6050 Gyro X
-    gyro_y:
-      name: MPU6050 Gyro Y
-    gyro_z:
-      name: MPU6050 Gyro z
-    temperature:
-      name: MPU6050 Temperature
+<<: !include common.yaml
diff --git a/tests/components/mpu6050/test.rp2040-ard.yaml b/tests/components/mpu6050/test.rp2040-ard.yaml
index 39c8506d2b..ee2c29ca4e 100644
--- a/tests/components/mpu6050/test.rp2040-ard.yaml
+++ b/tests/components/mpu6050/test.rp2040-ard.yaml
@@ -1,22 +1,5 @@
-i2c:
-  - id: i2c_mpu6050
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: mpu6050
-    address: 0x68
-    accel_x:
-      name: MPU6050 Accel X
-    accel_y:
-      name: MPU6050 Accel Y
-    accel_z:
-      name: MPU6050 Accel z
-    gyro_x:
-      name: MPU6050 Gyro X
-    gyro_y:
-      name: MPU6050 Gyro Y
-    gyro_z:
-      name: MPU6050 Gyro z
-    temperature:
-      name: MPU6050 Temperature
+<<: !include common.yaml
diff --git a/tests/components/mpu6886/common.yaml b/tests/components/mpu6886/common.yaml
new file mode 100644
index 0000000000..9c3e283cc3
--- /dev/null
+++ b/tests/components/mpu6886/common.yaml
@@ -0,0 +1,22 @@
+i2c:
+  - id: i2c_mpu6886
+    scl: ${scl_pin}
+    sda: ${sda_pin}
+
+sensor:
+  - platform: mpu6886
+    address: 0x68
+    accel_x:
+      name: MPU6886 Accel X
+    accel_y:
+      name: MPU6886 Accel Y
+    accel_z:
+      name: MPU6886 Accel z
+    gyro_x:
+      name: MPU6886 Gyro X
+    gyro_y:
+      name: MPU6886 Gyro Y
+    gyro_z:
+      name: MPU6886 Gyro z
+    temperature:
+      name: MPU6886 Temperature
diff --git a/tests/components/mpu6886/test.esp32-ard.yaml b/tests/components/mpu6886/test.esp32-ard.yaml
index 84e4d56739..63c3bd6afd 100644
--- a/tests/components/mpu6886/test.esp32-ard.yaml
+++ b/tests/components/mpu6886/test.esp32-ard.yaml
@@ -1,22 +1,5 @@
-i2c:
-  - id: i2c_mpu6886
-    scl: 16
-    sda: 17
+substitutions:
+  scl_pin: GPIO16
+  sda_pin: GPIO17
 
-sensor:
-  - platform: mpu6886
-    address: 0x68
-    accel_x:
-      name: MPU6886 Accel X
-    accel_y:
-      name: MPU6886 Accel Y
-    accel_z:
-      name: MPU6886 Accel z
-    gyro_x:
-      name: MPU6886 Gyro X
-    gyro_y:
-      name: MPU6886 Gyro Y
-    gyro_z:
-      name: MPU6886 Gyro z
-    temperature:
-      name: MPU6886 Temperature
+<<: !include common.yaml
diff --git a/tests/components/mpu6886/test.esp32-c3-ard.yaml b/tests/components/mpu6886/test.esp32-c3-ard.yaml
index fad51a80b4..ee2c29ca4e 100644
--- a/tests/components/mpu6886/test.esp32-c3-ard.yaml
+++ b/tests/components/mpu6886/test.esp32-c3-ard.yaml
@@ -1,22 +1,5 @@
-i2c:
-  - id: i2c_mpu6886
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: mpu6886
-    address: 0x68
-    accel_x:
-      name: MPU6886 Accel X
-    accel_y:
-      name: MPU6886 Accel Y
-    accel_z:
-      name: MPU6886 Accel z
-    gyro_x:
-      name: MPU6886 Gyro X
-    gyro_y:
-      name: MPU6886 Gyro Y
-    gyro_z:
-      name: MPU6886 Gyro z
-    temperature:
-      name: MPU6886 Temperature
+<<: !include common.yaml
diff --git a/tests/components/mpu6886/test.esp32-c3-idf.yaml b/tests/components/mpu6886/test.esp32-c3-idf.yaml
index fad51a80b4..ee2c29ca4e 100644
--- a/tests/components/mpu6886/test.esp32-c3-idf.yaml
+++ b/tests/components/mpu6886/test.esp32-c3-idf.yaml
@@ -1,22 +1,5 @@
-i2c:
-  - id: i2c_mpu6886
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: mpu6886
-    address: 0x68
-    accel_x:
-      name: MPU6886 Accel X
-    accel_y:
-      name: MPU6886 Accel Y
-    accel_z:
-      name: MPU6886 Accel z
-    gyro_x:
-      name: MPU6886 Gyro X
-    gyro_y:
-      name: MPU6886 Gyro Y
-    gyro_z:
-      name: MPU6886 Gyro z
-    temperature:
-      name: MPU6886 Temperature
+<<: !include common.yaml
diff --git a/tests/components/mpu6886/test.esp32-idf.yaml b/tests/components/mpu6886/test.esp32-idf.yaml
index 84e4d56739..63c3bd6afd 100644
--- a/tests/components/mpu6886/test.esp32-idf.yaml
+++ b/tests/components/mpu6886/test.esp32-idf.yaml
@@ -1,22 +1,5 @@
-i2c:
-  - id: i2c_mpu6886
-    scl: 16
-    sda: 17
+substitutions:
+  scl_pin: GPIO16
+  sda_pin: GPIO17
 
-sensor:
-  - platform: mpu6886
-    address: 0x68
-    accel_x:
-      name: MPU6886 Accel X
-    accel_y:
-      name: MPU6886 Accel Y
-    accel_z:
-      name: MPU6886 Accel z
-    gyro_x:
-      name: MPU6886 Gyro X
-    gyro_y:
-      name: MPU6886 Gyro Y
-    gyro_z:
-      name: MPU6886 Gyro z
-    temperature:
-      name: MPU6886 Temperature
+<<: !include common.yaml
diff --git a/tests/components/mpu6886/test.esp8266-ard.yaml b/tests/components/mpu6886/test.esp8266-ard.yaml
index fad51a80b4..ee2c29ca4e 100644
--- a/tests/components/mpu6886/test.esp8266-ard.yaml
+++ b/tests/components/mpu6886/test.esp8266-ard.yaml
@@ -1,22 +1,5 @@
-i2c:
-  - id: i2c_mpu6886
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: mpu6886
-    address: 0x68
-    accel_x:
-      name: MPU6886 Accel X
-    accel_y:
-      name: MPU6886 Accel Y
-    accel_z:
-      name: MPU6886 Accel z
-    gyro_x:
-      name: MPU6886 Gyro X
-    gyro_y:
-      name: MPU6886 Gyro Y
-    gyro_z:
-      name: MPU6886 Gyro z
-    temperature:
-      name: MPU6886 Temperature
+<<: !include common.yaml
diff --git a/tests/components/mpu6886/test.rp2040-ard.yaml b/tests/components/mpu6886/test.rp2040-ard.yaml
index fad51a80b4..ee2c29ca4e 100644
--- a/tests/components/mpu6886/test.rp2040-ard.yaml
+++ b/tests/components/mpu6886/test.rp2040-ard.yaml
@@ -1,22 +1,5 @@
-i2c:
-  - id: i2c_mpu6886
-    scl: 5
-    sda: 4
+substitutions:
+  scl_pin: GPIO5
+  sda_pin: GPIO4
 
-sensor:
-  - platform: mpu6886
-    address: 0x68
-    accel_x:
-      name: MPU6886 Accel X
-    accel_y:
-      name: MPU6886 Accel Y
-    accel_z:
-      name: MPU6886 Accel z
-    gyro_x:
-      name: MPU6886 Gyro X
-    gyro_y:
-      name: MPU6886 Gyro Y
-    gyro_z:
-      name: MPU6886 Gyro z
-    temperature:
-      name: MPU6886 Temperature
+<<: !include common.yaml
diff --git a/tests/components/mqtt_subscribe/common-ard.yaml b/tests/components/mqtt_subscribe/common-ard.yaml
new file mode 100644
index 0000000000..13ed311b17
--- /dev/null
+++ b/tests/components/mqtt_subscribe/common-ard.yaml
@@ -0,0 +1,36 @@
+wifi:
+  ssid: MySSID
+  password: password1
+
+mqtt:
+  broker: test.mosquitto.org
+  port: 1883
+  discovery: true
+  discovery_prefix: homeassistant
+  log_topic:
+  on_message:
+    topic: testing/sensor/testing_sensor/state
+    qos: 0
+    then:
+      - logger.log: Mqtt Test
+
+sensor:
+  - platform: mqtt_subscribe
+    name: MQTT Subscribe Sensor
+    topic: mqtt/topic
+    id: the_sensor
+    qos: 2
+    on_value:
+      - mqtt.publish_json:
+          topic: the/topic
+          payload: |-
+            root["key"] = id(the_sensor).state;
+            root["greeting"] = "Hello World";
+
+text_sensor:
+  - platform: mqtt_subscribe
+    name: MQTT Subscribe Text
+    topic: "the/topic"
+    qos: 2
+    on_value:
+      - logger.log: "Text sensor got value"
diff --git a/tests/components/mqtt_subscribe/common-idf.yaml b/tests/components/mqtt_subscribe/common-idf.yaml
new file mode 100644
index 0000000000..070672f15c
--- /dev/null
+++ b/tests/components/mqtt_subscribe/common-idf.yaml
@@ -0,0 +1,37 @@
+wifi:
+  ssid: MySSID
+  password: password1
+
+mqtt:
+  broker: test.mosquitto.org
+  port: 1883
+  discovery: true
+  discovery_prefix: homeassistant
+  idf_send_async: false
+  log_topic:
+  on_message:
+    topic: testing/sensor/testing_sensor/state
+    qos: 0
+    then:
+      - logger.log: Mqtt Test
+
+sensor:
+  - platform: mqtt_subscribe
+    name: MQTT Subscribe Sensor
+    topic: mqtt/topic
+    id: the_sensor
+    qos: 2
+    on_value:
+      - mqtt.publish_json:
+          topic: the/topic
+          payload: |-
+            root["key"] = id(the_sensor).state;
+            root["greeting"] = "Hello World";
+
+text_sensor:
+  - platform: mqtt_subscribe
+    name: MQTT Subscribe Text
+    topic: "the/topic"
+    qos: 2
+    on_value:
+      - logger.log: "Text sensor got value"
diff --git a/tests/components/mqtt_subscribe/test.esp32-ard.yaml b/tests/components/mqtt_subscribe/test.esp32-ard.yaml
index 13ed311b17..28589ee06c 100644
--- a/tests/components/mqtt_subscribe/test.esp32-ard.yaml
+++ b/tests/components/mqtt_subscribe/test.esp32-ard.yaml
@@ -1,36 +1 @@
-wifi:
-  ssid: MySSID
-  password: password1
-
-mqtt:
-  broker: test.mosquitto.org
-  port: 1883
-  discovery: true
-  discovery_prefix: homeassistant
-  log_topic:
-  on_message:
-    topic: testing/sensor/testing_sensor/state
-    qos: 0
-    then:
-      - logger.log: Mqtt Test
-
-sensor:
-  - platform: mqtt_subscribe
-    name: MQTT Subscribe Sensor
-    topic: mqtt/topic
-    id: the_sensor
-    qos: 2
-    on_value:
-      - mqtt.publish_json:
-          topic: the/topic
-          payload: |-
-            root["key"] = id(the_sensor).state;
-            root["greeting"] = "Hello World";
-
-text_sensor:
-  - platform: mqtt_subscribe
-    name: MQTT Subscribe Text
-    topic: "the/topic"
-    qos: 2
-    on_value:
-      - logger.log: "Text sensor got value"
+<<: !include common-ard.yaml
diff --git a/tests/components/mqtt_subscribe/test.esp32-c3-ard.yaml b/tests/components/mqtt_subscribe/test.esp32-c3-ard.yaml
index 13ed311b17..28589ee06c 100644
--- a/tests/components/mqtt_subscribe/test.esp32-c3-ard.yaml
+++ b/tests/components/mqtt_subscribe/test.esp32-c3-ard.yaml
@@ -1,36 +1 @@
-wifi:
-  ssid: MySSID
-  password: password1
-
-mqtt:
-  broker: test.mosquitto.org
-  port: 1883
-  discovery: true
-  discovery_prefix: homeassistant
-  log_topic:
-  on_message:
-    topic: testing/sensor/testing_sensor/state
-    qos: 0
-    then:
-      - logger.log: Mqtt Test
-
-sensor:
-  - platform: mqtt_subscribe
-    name: MQTT Subscribe Sensor
-    topic: mqtt/topic
-    id: the_sensor
-    qos: 2
-    on_value:
-      - mqtt.publish_json:
-          topic: the/topic
-          payload: |-
-            root["key"] = id(the_sensor).state;
-            root["greeting"] = "Hello World";
-
-text_sensor:
-  - platform: mqtt_subscribe
-    name: MQTT Subscribe Text
-    topic: "the/topic"
-    qos: 2
-    on_value:
-      - logger.log: "Text sensor got value"
+<<: !include common-ard.yaml
diff --git a/tests/components/mqtt_subscribe/test.esp32-c3-idf.yaml b/tests/components/mqtt_subscribe/test.esp32-c3-idf.yaml
index 070672f15c..2cb6d82536 100644
--- a/tests/components/mqtt_subscribe/test.esp32-c3-idf.yaml
+++ b/tests/components/mqtt_subscribe/test.esp32-c3-idf.yaml
@@ -1,37 +1 @@
-wifi:
-  ssid: MySSID
-  password: password1
-
-mqtt:
-  broker: test.mosquitto.org
-  port: 1883
-  discovery: true
-  discovery_prefix: homeassistant
-  idf_send_async: false
-  log_topic:
-  on_message:
-    topic: testing/sensor/testing_sensor/state
-    qos: 0
-    then:
-      - logger.log: Mqtt Test
-
-sensor:
-  - platform: mqtt_subscribe
-    name: MQTT Subscribe Sensor
-    topic: mqtt/topic
-    id: the_sensor
-    qos: 2
-    on_value:
-      - mqtt.publish_json:
-          topic: the/topic
-          payload: |-
-            root["key"] = id(the_sensor).state;
-            root["greeting"] = "Hello World";
-
-text_sensor:
-  - platform: mqtt_subscribe
-    name: MQTT Subscribe Text
-    topic: "the/topic"
-    qos: 2
-    on_value:
-      - logger.log: "Text sensor got value"
+<<: !include common-idf.yaml
diff --git a/tests/components/mqtt_subscribe/test.esp32-idf.yaml b/tests/components/mqtt_subscribe/test.esp32-idf.yaml
index 070672f15c..2cb6d82536 100644
--- a/tests/components/mqtt_subscribe/test.esp32-idf.yaml
+++ b/tests/components/mqtt_subscribe/test.esp32-idf.yaml
@@ -1,37 +1 @@
-wifi:
-  ssid: MySSID
-  password: password1
-
-mqtt:
-  broker: test.mosquitto.org
-  port: 1883
-  discovery: true
-  discovery_prefix: homeassistant
-  idf_send_async: false
-  log_topic:
-  on_message:
-    topic: testing/sensor/testing_sensor/state
-    qos: 0
-    then:
-      - logger.log: Mqtt Test
-
-sensor:
-  - platform: mqtt_subscribe
-    name: MQTT Subscribe Sensor
-    topic: mqtt/topic
-    id: the_sensor
-    qos: 2
-    on_value:
-      - mqtt.publish_json:
-          topic: the/topic
-          payload: |-
-            root["key"] = id(the_sensor).state;
-            root["greeting"] = "Hello World";
-
-text_sensor:
-  - platform: mqtt_subscribe
-    name: MQTT Subscribe Text
-    topic: "the/topic"
-    qos: 2
-    on_value:
-      - logger.log: "Text sensor got value"
+<<: !include common-idf.yaml
diff --git a/tests/components/mqtt_subscribe/test.esp8266-ard.yaml b/tests/components/mqtt_subscribe/test.esp8266-ard.yaml
index 13ed311b17..28589ee06c 100644
--- a/tests/components/mqtt_subscribe/test.esp8266-ard.yaml
+++ b/tests/components/mqtt_subscribe/test.esp8266-ard.yaml
@@ -1,36 +1 @@
-wifi:
-  ssid: MySSID
-  password: password1
-
-mqtt:
-  broker: test.mosquitto.org
-  port: 1883
-  discovery: true
-  discovery_prefix: homeassistant
-  log_topic:
-  on_message:
-    topic: testing/sensor/testing_sensor/state
-    qos: 0
-    then:
-      - logger.log: Mqtt Test
-
-sensor:
-  - platform: mqtt_subscribe
-    name: MQTT Subscribe Sensor
-    topic: mqtt/topic
-    id: the_sensor
-    qos: 2
-    on_value:
-      - mqtt.publish_json:
-          topic: the/topic
-          payload: |-
-            root["key"] = id(the_sensor).state;
-            root["greeting"] = "Hello World";
-
-text_sensor:
-  - platform: mqtt_subscribe
-    name: MQTT Subscribe Text
-    topic: "the/topic"
-    qos: 2
-    on_value:
-      - logger.log: "Text sensor got value"
+<<: !include common-ard.yaml
diff --git a/tests/components/ms5611/common.yaml b/tests/components/ms5611/common.yaml
new file mode 100644
index 0000000000..d0417faa86
--- /dev/null
+++ b/tests/components/ms5611/common.yaml
@@ -0,0 +1,13 @@
+i2c:
+  - id: i2c_ms5611
+    scl: ${i2c_scl}
+    sda: ${i2c_sda}
+
+sensor:
+  - platform: ms5611
+    temperature:
+      name: Outside Temperature
+    pressure:
+      name: Outside Pressure
+    address: 0x77
+    update_interval: 15s
diff --git a/tests/components/ms5611/test.esp32-ard.yaml b/tests/components/ms5611/test.esp32-ard.yaml
index b090eeaa93..1037d5d35b 100644
--- a/tests/components/ms5611/test.esp32-ard.yaml
+++ b/tests/components/ms5611/test.esp32-ard.yaml
@@ -1,13 +1,5 @@
-i2c:
-  - id: i2c_ms5611
-    scl: 16
-    sda: 17
+substitutions:
+  i2c_scl: GPIO16
+  i2c_sda: GPIO17
 
-sensor:
-  - platform: ms5611
-    temperature:
-      name: Outside Temperature
-    pressure:
-      name: Outside Pressure
-    address: 0x77
-    update_interval: 15s
+<<: !include common.yaml
diff --git a/tests/components/ms5611/test.esp32-c3-ard.yaml b/tests/components/ms5611/test.esp32-c3-ard.yaml
index 8f18501eef..d7ae0d5161 100644
--- a/tests/components/ms5611/test.esp32-c3-ard.yaml
+++ b/tests/components/ms5611/test.esp32-c3-ard.yaml
@@ -1,13 +1,5 @@
-i2c:
-  - id: i2c_ms5611
-    scl: 5
-    sda: 4
+substitutions:
+  i2c_scl: GPIO5
+  i2c_sda: GPIO4
 
-sensor:
-  - platform: ms5611
-    temperature:
-      name: Outside Temperature
-    pressure:
-      name: Outside Pressure
-    address: 0x77
-    update_interval: 15s
+<<: !include common.yaml
diff --git a/tests/components/ms5611/test.esp32-c3-idf.yaml b/tests/components/ms5611/test.esp32-c3-idf.yaml
index 8f18501eef..d7ae0d5161 100644
--- a/tests/components/ms5611/test.esp32-c3-idf.yaml
+++ b/tests/components/ms5611/test.esp32-c3-idf.yaml
@@ -1,13 +1,5 @@
-i2c:
-  - id: i2c_ms5611
-    scl: 5
-    sda: 4
+substitutions:
+  i2c_scl: GPIO5
+  i2c_sda: GPIO4
 
-sensor:
-  - platform: ms5611
-    temperature:
-      name: Outside Temperature
-    pressure:
-      name: Outside Pressure
-    address: 0x77
-    update_interval: 15s
+<<: !include common.yaml
diff --git a/tests/components/ms5611/test.esp32-idf.yaml b/tests/components/ms5611/test.esp32-idf.yaml
index b090eeaa93..1037d5d35b 100644
--- a/tests/components/ms5611/test.esp32-idf.yaml
+++ b/tests/components/ms5611/test.esp32-idf.yaml
@@ -1,13 +1,5 @@
-i2c:
-  - id: i2c_ms5611
-    scl: 16
-    sda: 17
+substitutions:
+  i2c_scl: GPIO16
+  i2c_sda: GPIO17
 
-sensor:
-  - platform: ms5611
-    temperature:
-      name: Outside Temperature
-    pressure:
-      name: Outside Pressure
-    address: 0x77
-    update_interval: 15s
+<<: !include common.yaml
diff --git a/tests/components/ms5611/test.esp8266-ard.yaml b/tests/components/ms5611/test.esp8266-ard.yaml
index 8f18501eef..d7ae0d5161 100644
--- a/tests/components/ms5611/test.esp8266-ard.yaml
+++ b/tests/components/ms5611/test.esp8266-ard.yaml
@@ -1,13 +1,5 @@
-i2c:
-  - id: i2c_ms5611
-    scl: 5
-    sda: 4
+substitutions:
+  i2c_scl: GPIO5
+  i2c_sda: GPIO4
 
-sensor:
-  - platform: ms5611
-    temperature:
-      name: Outside Temperature
-    pressure:
-      name: Outside Pressure
-    address: 0x77
-    update_interval: 15s
+<<: !include common.yaml
diff --git a/tests/components/ms5611/test.rp2040-ard.yaml b/tests/components/ms5611/test.rp2040-ard.yaml
index 8f18501eef..d7ae0d5161 100644
--- a/tests/components/ms5611/test.rp2040-ard.yaml
+++ b/tests/components/ms5611/test.rp2040-ard.yaml
@@ -1,13 +1,5 @@
-i2c:
-  - id: i2c_ms5611
-    scl: 5
-    sda: 4
+substitutions:
+  i2c_scl: GPIO5
+  i2c_sda: GPIO4
 
-sensor:
-  - platform: ms5611
-    temperature:
-      name: Outside Temperature
-    pressure:
-      name: Outside Pressure
-    address: 0x77
-    update_interval: 15s
+<<: !include common.yaml