Added tests for diagnostics