From bf529ef600fa9ef2034d0412c198b2121f2b94f2 Mon Sep 17 00:00:00 2001 From: rnveach Date: Thu, 15 Oct 2015 22:53:56 -0400 Subject: Issue #2161: unify test input locations for blocks package --- .../checkstyle/checks/naming/InputCatchOnly.java | 34 ++++++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100644 src/test/resources/com/puppycrawl/tools/checkstyle/checks/naming/InputCatchOnly.java (limited to 'src/test/resources/com/puppycrawl/tools/checkstyle/checks/naming/InputCatchOnly.java') diff --git a/src/test/resources/com/puppycrawl/tools/checkstyle/checks/naming/InputCatchOnly.java b/src/test/resources/com/puppycrawl/tools/checkstyle/checks/naming/InputCatchOnly.java new file mode 100644 index 000000000..ac1a01a11 --- /dev/null +++ b/src/test/resources/com/puppycrawl/tools/checkstyle/checks/naming/InputCatchOnly.java @@ -0,0 +1,34 @@ +package com.puppycrawl.tools.checkstyle.checks.naming; + +/** + * Test case for skipping over catch names. + **/ +public class InputCatchOnly { + int foo() { + if (System.currentTimeMillis() > 1000) + return 1; + + int test = 0; + + try + { + return 1; + } + catch (Exception e) + { + return 0; + } + } + + public InputCatchOnly() + { + return; + } + + class InnerFoo + { + public void fooInnerMethod () + { + } + } +} -- cgit v1.2.3