So would you be interested in an array containing the other like a superset? Or if 2 arrays are exactly the same?
Not sure if Godot has any specific function for it but the code is quite simple
func arrays_have_same_content(array1, array2):
if array1.size() != array2.size(): return false
for item in array1:
if !array2.has(item):
return false
if array1.count(item) != array2.count(item):
return false
return true
This function checks if the 2 arrays are exactly the same. In case you need to only check if array1 contains all the elements of array2 you could reaarange the code like this
func arrays_contains_array(array1, array2):
for item in array2:
if !array1.has(item):
return false
if array2.count(item) != array1.count(item):
return false
return true