Skipping Command

I’m trying to run a series of tests by sending a string to firebase from another python script that determines that string. I only need to send the string if it is not empty and skip the job in the other case where “no tests are needed” this is what i did but I keep getting command not found.

if ["$(python3 project/.circleci/tests_from_files.py)" 
   == "no tests are needed"]; then
   circleci-agent step halt
fi