I am not an expert on the Exec binding by any means but my advice is to use
val results = executeCommandLine("/etc/openhab/configruations/scripts/test.sh", 5000)
logInfo("Test", results)
in a rule while trying to debug Exec. This is the only way I’ve found to see the error that your script is producing and seeing what the script is producing can save hours of experimentation trying to figure out what, if anything the script is doing.
Once it works in a rule you can usually transfer the script back to an Exec bound Item, though I have personally left it in a rule so I can get a log of the results every time it runs which saves me some steps when trying to debug any problems that pop up.
One thing I will caution you about is there is some unexpected behavior in the way OH starts up. It runs a script that changes the permissions on all the files OH owns which will strip the execution permission off of your test.sh script. See this thread for details. An issue was created to fix this and I posted a work around in the mean time.