@10up/cypress-wp-utils
    Preparing search index...

    Function uploadMedia

    • Upload a media file

      Parameters

      • filePath: string

        A path to a file within the project root (Eg: 'tests/cypress/fixtures/10up.png').

      Returns void

      Media ID with upload status. eg: { success: true, mediaId: 123}, for failure { success: false, errorMessage: '"file" has failed to upload' }

      Upload a media file.

      cy.uploadMedia('tests/cypress/fixtures/image.png')