Improvements in composer and recipe

 * working in contextual mode
Added tests cases for contextual mode working
Fixed coding issue reported from scrutinizer

 * namespace of type string is not a sub-type of boolean.