Skip to content

Instantly share code, notes, and snippets.

@wessmith
Created October 20, 2015 19:03
Show Gist options
  • Save wessmith/df5785625ed4a1025e8c to your computer and use it in GitHub Desktop.
Save wessmith/df5785625ed4a1025e8c to your computer and use it in GitHub Desktop.
Generate warnings when focusing tests with Specta
#!/bin/sh
FOCUS="fit\(|fdescribe\(|fcontext\("
find "${SRCROOT}/Path/To/Tests" \( -name "*.m" \) -print0 | xargs -0 egrep --with-filename --line-number --only-matching "($FOCUS).*\$" | perl -p -e "s/($FOCUS)/ warning: \$1/"
@wessmith
Copy link
Author

@modocache Love the idea of including it in Specta!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment