Add caps filter to get specific outformat
Only check state when we got a pipeline
Fix test build