package flow
import (
"testing"
"github.com/projectdiscovery/nuclei/v3/pkg/operators"
"github.com/stretchr/testify/require"
)
func TestHasMatchersPanicRegression(t *testing.T) {
require.NotPanics(t, func() {
all := []*operators.Operators{nil}
result := hasMatchers(all)
require.False(t, result)
}, "hasMatchers should not panic with nil element in slice")
require.NotPanics(t, func() {
all := []*operators.Operators{nil, {}}
result := hasMatchers(all)
require.False(t, result)
}, "hasMatchers should not panic with mix of nil and empty operators")
}
func TestHasOperatorsPanicRegression(t *testing.T) {
require.NotPanics(t, func() {
all := []*operators.Operators{nil}
result := hasOperators(all)
require.False(t, result)
}, "hasOperators should not panic with nil element in slice")
}