Executable 'rubocop' not found

Hello everyone. I’m having a problem when i run build.sh locally, the error triggers when i run the ./build.sh test_generic command and it says “Executable rubocop not found” the code i’m trying to upload is written in Ruby, i added prelude comments where i set the command “rubocop -l XXX.rb” for linting and its output, i tried again with no comments at all and the same error, i searched on the web and in this forum and didn’t found a similar issue, i have rubocop installed and when i try to use it works normally. Also i tried to edit my linting line and put /usr/local/bin/rubocop instead and also didn’t work. Any help pointing me to the right path will be appreciated. Thanks