Browse code

Merge pull request #51188 from thaJeztah/integration_less_version_checks

integration: remove some version-gates for API < v1.44

Austin Vazquez authored on 2025/10/17 05:38:08
Showing 6 changed files
... ...
@@ -696,7 +696,6 @@ func TestCreateWithMultipleEndpointSettings(t *testing.T) {
696 696
 
697 697
 func TestCreateWithCustomMACs(t *testing.T) {
698 698
 	skip.If(t, testEnv.DaemonInfo.OSType == "windows")
699
-	skip.If(t, versions.LessThan(testEnv.DaemonAPIVersion(), "1.44"), "requires API v1.44")
700 699
 
701 700
 	ctx := setupTest(t)
702 701
 	apiClient := testEnv.APIClient()
... ...
@@ -4,7 +4,6 @@ import (
4 4
 	"strings"
5 5
 	"testing"
6 6
 
7
-	"github.com/moby/moby/api/types/versions"
8 7
 	"github.com/moby/moby/client"
9 8
 	"github.com/moby/moby/v2/integration/internal/container"
10 9
 	"gotest.tools/v3/assert"
... ...
@@ -13,7 +12,6 @@ import (
13 13
 
14 14
 func TestExecConsoleSize(t *testing.T) {
15 15
 	skip.If(t, testEnv.DaemonInfo.OSType != "linux")
16
-	skip.If(t, versions.LessThan(testEnv.DaemonAPIVersion(), "1.42"), "skip test from new feature")
17 16
 
18 17
 	ctx := setupTest(t)
19 18
 	apiClient := testEnv.APIClient()
... ...
@@ -8,7 +8,6 @@ import (
8 8
 	"testing"
9 9
 
10 10
 	containertypes "github.com/moby/moby/api/types/container"
11
-	"github.com/moby/moby/api/types/versions"
12 11
 	"github.com/moby/moby/client"
13 12
 	"github.com/moby/moby/v2/integration/internal/container"
14 13
 	"github.com/moby/moby/v2/internal/testutil"
... ...
@@ -301,7 +300,6 @@ func TestDaemonIpcModeShareableFromConfig(t *testing.T) {
301 301
 // by default, even when the daemon default is private.
302 302
 func TestIpcModeOlderClient(t *testing.T) {
303 303
 	apiClient := testEnv.APIClient()
304
-	skip.If(t, versions.LessThan(apiClient.ClientVersion(), "1.40"), "requires client API >= 1.40")
305 304
 
306 305
 	t.Parallel()
307 306
 
... ...
@@ -13,7 +13,6 @@ import (
13 13
 	"github.com/docker/go-units"
14 14
 	"github.com/moby/moby/api/pkg/stdcopy"
15 15
 	containertypes "github.com/moby/moby/api/types/container"
16
-	"github.com/moby/moby/api/types/versions"
17 16
 	"github.com/moby/moby/client"
18 17
 	"github.com/moby/moby/v2/integration/internal/container"
19 18
 	net "github.com/moby/moby/v2/integration/internal/network"
... ...
@@ -174,7 +173,6 @@ func TestPrivilegedHostDevices(t *testing.T) {
174 174
 
175 175
 func TestRunConsoleSize(t *testing.T) {
176 176
 	skip.If(t, testEnv.DaemonInfo.OSType != "linux")
177
-	skip.If(t, versions.LessThan(testEnv.DaemonAPIVersion(), "1.42"), "skip test from new feature")
178 177
 
179 178
 	ctx := setupTest(t)
180 179
 	apiClient := testEnv.APIClient()
... ...
@@ -15,7 +15,6 @@ import (
15 15
 
16 16
 	"github.com/cpuguy83/tar2go"
17 17
 	"github.com/moby/go-archive/compression"
18
-	"github.com/moby/moby/api/types/versions"
19 18
 	"github.com/moby/moby/client"
20 19
 	"github.com/moby/moby/v2/integration/internal/build"
21 20
 	"github.com/moby/moby/v2/integration/internal/container"
... ...
@@ -91,8 +90,6 @@ func TestSaveCheckTimes(t *testing.T) {
91 91
 
92 92
 // Regression test for https://github.com/moby/moby/issues/47065
93 93
 func TestSaveOCI(t *testing.T) {
94
-	skip.If(t, versions.LessThan(testEnv.DaemonAPIVersion(), "1.44"), "OCI layout support was introduced in v25")
95
-
96 94
 	ctx := setupTest(t)
97 95
 	apiClient := testEnv.APIClient()
98 96
 
... ...
@@ -13,7 +13,6 @@ import (
13 13
 	"github.com/google/go-cmp/cmp/cmpopts"
14 14
 	containertypes "github.com/moby/moby/api/types/container"
15 15
 	networktypes "github.com/moby/moby/api/types/network"
16
-	"github.com/moby/moby/api/types/versions"
17 16
 	"github.com/moby/moby/client"
18 17
 	"github.com/moby/moby/v2/daemon/container"
19 18
 	"github.com/moby/moby/v2/daemon/libnetwork/drivers/bridge"
... ...
@@ -32,8 +31,6 @@ import (
32 32
 )
33 33
 
34 34
 func TestCreateWithMultiNetworks(t *testing.T) {
35
-	skip.If(t, versions.LessThan(testEnv.DaemonAPIVersion(), "1.44"), "requires API v1.44")
36
-
37 35
 	ctx := setupTest(t)
38 36
 	apiClient := testEnv.APIClient()
39 37