wp-graphql / wpgraphql-acf

Re-architecture of WPGraphQL for ACF
GNU General Public License v3.0
85 stars 12 forks source link

Fix tests for ACF Blocks #92

Closed jasonbahl closed 1 year ago

jasonbahl commented 1 year ago

Description

Currently the tests for ACF Blocks are failing in different environments and for the v2.0.0-beta.5.0.0 release I marked the tests skipped to unblock the release.

We need to investigate why the tests are failing (I believe it's a specific plugin version conflict in some of the matrix combinations, but need to dig in)

Steps to reproduce

  1. Remove the markTestSkipped flag from the testFieldOnAcfBlock test in tests/_support/WPUnit/AcfFieldTestCase.php
  2. run the tests locally (they work)
  3. run the tests in Github (they fail)

So, it seems to either be an issue with env vars or something from the matrix or something to that tune. 🤔

PHP or JSON export of the ACF Field Group(s)

No response

Additional context

No response

WPGraphQL Version

1.16.0

WPGraphQL For ACF Version

v2.0.0-beta.5.0.0

ACF (Advanced Custom Fields) Version. Free or Pro?

PRO

WordPress Version

6.3

PHP Version

8.2

Additional enviornment details

Here's my local .env

DEBUG=1
SUITES=wpunit
ACF_LICENSE_KEY=${secret}
ACF_VERSION="6.2.0"
ACF_PRO=true
ACF_PLUGIN_SLUG="advanced-custom-fields-pro"
WPGRAPHQL_CONTENT_BLOCKS=true
WPGRAPHQL_CONTENT_BLOCKS_VERSION=latest
ACF_EXTENDED_VERSION="latest"
ACF_EXTENDED_LICENSE_KEY=${secret}
ACF_EXTENDED_PLUGIN_SLUG="acf-extended-pro"

Please confirm that you have searched existing issues in the repo.

Please confirm that you have disabled ALL plugins except for WPGraphQL, WPGraphQL For ACF, ACF, etc.

jasonbahl commented 1 year ago

I have the tests passing properly with WPGraphQL Content Blocks active now. See: https://github.com/wp-graphql/wpgraphql-acf/actions/runs/6318796619/job/17158557310?pr=94#step:7:1338

Next step is to fill-in the missing tests for the various field types that don't have the block test criteria defined.