package im

import (
	"context"
	"testing"

	"github.com/stretchr/testify/require"
)

func TestLoadScopeEventRecipientsExplicitEmptyAudienceDoesNotFallBackToScope(t *testing.T) {
	t.Parallel()

	// A nil queryer is intentional: explicit-empty targeting must return before
	// any broad membership query can run.
	recipients, err := loadScopeEventRecipientsForMembers(
		context.Background(),
		nil,
		"wsp_empty_audience",
		"tsk_empty_audience",
		nil,
		true,
	)

	require.NoError(t, err)
	require.Empty(t, recipients)
}
