Error coming in cake bake all

i am using Ubuntu 22.04 with apache2 and mariadb server with cakephp version 4

when using cake bake all table_name
error comes
Error: Undefined constant “TESTS”
#0 /usr/share/php/Cake/Console/Shell.php(508): TaskCollection->load()
#1 /usr/share/php/Cake/Console/Command/BakeShell.php(242): Shell->__get()
#2 /usr/share/php/Cake/Console/Shell.php(430): BakeShell->getOptionParser()
#3 /usr/share/php/Cake/Console/ShellDispatcher.php(222): Shell->runCommand()
#4 /usr/share/php/Cake/Console/ShellDispatcher.php(66): ShellDispatcher->dispatch()
#5 /usr/share/php/Cake/Console/cake.php(54): ShellDispatcher::run()
#6 {main}

any help will be great. :slight_smile:

found the solution, thanks
was running command in wrong folder.

1 Like