Skip to content

Instantly share code, notes, and snippets.

@maplesteve
maplesteve / build.xml
Created March 10, 2013 18:35
Sample build.xml to use oclint for PMD analysis in Jenkins. See the post mentioned in the first comment for details.
<?xml version="1.0" encoding="UTF-8"?>
<project name="fooProject" default="build-fooProject">
<property environment="env"/>
<target name="build-fooProject" depends="prepare,oclint" />
<target name="clean" description="Cleanup build artifacts">
<delete dir="${basedir}/build/oclint" />
</target>
@maplesteve
maplesteve / UnnecessaryNilTest.m
Last active December 28, 2015 00:49
Testcase for possible OClint false positive. Fails in test cases #5 and #7.
//
// UnnecessaryNilTest.m
//
#import <XCTest/XCTest.h>
@interface MySender : NSObject
- (BOOL)returnNO;
- (BOOL)returnYES;
@end