diff --git a/.github/workflows/windows.yml b/.github/workflows/windows.yml index 839812e6..57f014ca 100644 --- a/.github/workflows/windows.yml +++ b/.github/workflows/windows.yml @@ -17,8 +17,11 @@ jobs: uses: actions/checkout@v2 - name: Run Windows Integration Tests run: | + # required for running Volume and Disk tests + Install-WindowsFeature -name Hyper-V-PowerShell + $env:CSI_PROXY_GH_ACTIONS="TRUE" - go test -v -race ./integrationtests/... + go test --timeout 20m -v -race ./integrationtests/... unit_tests: strategy: matrix: diff --git a/integrationtests/disk_test.go b/integrationtests/disk_test.go index f93228f5..84f8edc3 100644 --- a/integrationtests/disk_test.go +++ b/integrationtests/disk_test.go @@ -78,7 +78,6 @@ func TestDisk(t *testing.T) { }) t.Run("Get/SetDiskState", func(t *testing.T) { - skipTestOnCondition(t, isRunningOnGhActions()) client, err := disk.New(diskapi.New()) require.Nil(t, err) @@ -143,7 +142,6 @@ func TestDisk(t *testing.T) { }) t.Run("PartitionDisk", func(t *testing.T) { - skipTestOnCondition(t, isRunningOnGhActions()) var err error client, err := disk.New(diskapi.New()) diff --git a/integrationtests/volume_test.go b/integrationtests/volume_test.go index a4af79e2..3ce3fab4 100644 --- a/integrationtests/volume_test.go +++ b/integrationtests/volume_test.go @@ -21,9 +21,6 @@ func TestVolume(t *testing.T) { negativeVolumeTests(t) }) - // TODO: These tests will fail on Github Actions because Hyper-V is disabled - // see https://github.com/actions/virtual-environments/pull/2525 - // these tests should be considered frozen from the API point of view volumeClient, err := volume.New(volumeapi.New()) require.Nil(t, err) @@ -32,12 +29,10 @@ func TestVolume(t *testing.T) { require.Nil(t, err) t.Run("MountVolume", func(t *testing.T) { - skipTestOnCondition(t, isRunningOnGhActions()) mountVolumeTests(diskClient, volumeClient, t) }) t.Run("GetClosestVolumeFromTargetPath", func(t *testing.T) { - skipTestOnCondition(t, isRunningOnGhActions()) getClosestVolumeFromTargetPathTests(diskClient, volumeClient, t) }) }