Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test: Add querybuilder test #15720

Draft
wants to merge 7 commits into
base: 3.x
Choose a base branch
from

Conversation

bzy107
Copy link
Contributor

@bzy107 bzy107 commented Feb 25, 2025

Description

I added a test to investigate the cause of #12554.

Additionally, I reproduced the test that results in the error from issue #12554, but I haven't included it in this commit. If you plan to investigate, please add the following test to your investigation.

it('can modal actions during text constraint', function () {
    $posts = Post::factory()->count(10)->create();
    $content = $posts->first()->content;
    $post = Post::where('content', $content);

    livewire(PostsQueryBuilderTable::class)
        ->assertCanSeeTableRecords($posts)
        ->queryBuilderTable('content', 'contains', $content)
        ->assertCanSeeTableRecords($post->get())
        ->callTableAction(DeleteAction::class, $post->first());

    assertSoftDeleted($post->first());
});

Here are the results of this test:

   FAILED  Tests\src\Tables\Filters\QueryBuilderTest > it can modal actions during text constraint                                                                                                                                                  Error
  Maximum call stack size of 8339456 bytes (zend.max_allowed_stack_size - zend.reserved_stack_size) reached. Infinite recursion?

Visual changes

Functional changes

  • Code style has been fixed by running the composer cs command.
  • Changes have been tested to not break existing functionality.
  • Documentation is up-to-date.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working chore
Projects
Status: Todo
Development

Successfully merging this pull request may close these issues.

2 participants