testttt(){
echo after trapp
}
test(){
echo inside testcode
exit 2
}
trap 'testttt' 2
test
When i run the script i get output ->inside testcode But I was expecting ->inside testcode after trapp Why isnt trap 'testttt' 2 capturing testttt()