Skip to content

Instantly share code, notes, and snippets.

View steinim's full-sized avatar

Stein Inge Morisbak steinim

View GitHub Profile
@steinim
steinim / MyIntegrationTest.java
Created September 11, 2011 08:49
Integration test with Spring
@IfProfileValue(name = "integration", value = "true")
@RunWith(SpringJUnit4ClassRunner.class)
@ContextConfiguration(locations = { "/applicationContext-itest.xml" })
public class MyIntegrationTest {
...
@Test
public void is_this_integration_test_working() {
...
}
...
@steinim
steinim / pom.xml
Created September 11, 2011 08:47
Slow task profile with activation property
<profile>
<id>slowTask</id>
<activation>
<property>
<name>!skipSlowTask</name>
</property>
</activation>
<build>
<plugins>
<plugin>
@steinim
steinim / pom.xml
Created September 5, 2011 13:27
Inkludering av bakdør ved bruk av profilen 'dev' - jetty-maven-plugin
...
<build>
...
<plugins>
...
<plugin>
<groupId>org.mortbay.jetty</groupId>
<artifactId>jetty-maven-plugin</artifactId>
<configuration>
...
@steinim
steinim / web.xml
Created September 5, 2011 13:11
Inkludering av bakdør ved bruk av profilen 'dev' - web.xml
...
<!-- Filters -->
<filter>
<filter-name>...</filter-name>
<filter-class>...</filter-class>
</filter>
...
${backdoor.filter}
...
<!-- Filter mappings -->
@steinim
steinim / pom.xml
Created September 5, 2011 12:51
Inkludering av bakdør ved bruk av profilen 'dev'
...
<build>
...
<plugins>
...
<plugin>
<artifactId>maven-war-plugin</artifactId>
<configuration>
<filteringDeploymentDescriptors>true</filteringDeploymentDescriptors>
<packagingExcludes>${war.packaging.excludes}</packagingExcludes>