Maven Postman plugin failing to email report

Hi,  

I am having some trouble getting the Maven Postman plugin to mail my surefire test report.  I'm a beginner so there is likely an obvious mistake here.  I  will post my POM file below in case it shows any obvious cause. I have  tried running clean, site, deploy and, although the report is generated,  it does not get mailed.  I'm not clear which maven goal I should be  running to get the report generated.  Any help much appreciated.

  1. <?xml version="1.0" encoding="UTF-8"?>  
  2. <project xmlns="http://maven.apache.org/POM/4.0.0"  
  3.          xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"  
  4.          xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">  
  5.   <modelVersion>4.0.0</modelVersion>  
  6.   <groupId>TrustOne</groupId>  
  7.   <artifactId>TrustOne</artifactId>  
  8.   <version>1.0</version>  
  9.   <dependencies>  
  10.     <dependency>  
  11.       <groupId>org.seleniumhq.selenium</groupId>  
  12.       <artifactId>selenium-java</artifactId>  
  13.       <version>2.34.0</version>  
  14.     </dependency>  
  15.     <dependency>  
  16.       <groupId>junit</groupId>  
  17.       <artifactId>junit</artifactId>  
  18.       <version>4.11</version>  
  19.       <scope>test</scope>  
  20.     </dependency>  
  21.     <dependency>  
  22.       <groupId>org.apache.maven.surefire</groupId>  
  23.       <artifactId>surefire</artifactId>  
  24.       <version>2.15</version>  
  25.       <type>pom</type>  
  26.     </dependency>  
  27.   </dependencies>  
  28.   <build>  
  29.     <plugins>  
  30.       <plugin>  
  31.         <groupId>org.apache.maven.plugins</groupId>  
  32.         <artifactId>maven-compiler-plugin</artifactId>  
  33.         <version>3.1</version>  
  34.         <configuration>  
  35.           <source>1.7</source>  
  36.           <target>1.7</target>  
  37.         </configuration>  
  38.       </plugin>  
  39.       <plugin>  
  40.         <groupId>org.apache.maven.plugins</groupId>  
  41.         <artifactId>maven-site-plugin</artifactId>  
  42.         <version>3.0-beta-3</version>  
  43.       </plugin>  
  44.       <plugin>  
  45.         <groupId>ch.fortysix</groupId>  
  46.         <artifactId>maven-postman-plugin</artifactId>  
  47.         <version>0.1.6</version>  
  48.         <executions>  
  49.           <execution>  
  50.             <id>send_an_email</id>  
  51.             <phase>deploy</phase>  
  52.             <goals>  
  53.               <goal>send-mail</goal>  
  54.             </goals>  
  55.             <inherited>true</inherited>  
  56.             <configuration>  
  57.               <mailhost>smtp.gmail.com</mailhost>  
  58.               <mailport>995</mailport>  
  59.               <mailssl>true</mailssl>  
  60.               <mailAltConfig>true</mailAltConfig>  
  61.               <mailuser>myemail@gmail.com</mailuser>  
  62.               <mailpassword>password1</mailpassword>  
  63.               <from<davidjsmithers</from>  
  64.               <receivers>  
  65.                 <receiver>myemail@gmail.com</receiver>  
  66.                 <receiver>myemail@gmail.com</receiver>  
  67.               </receivers>  
  68.               <subject>Property Integrity Report</subject>  
  69.               <failonerror>false</failonerror>  
  70.               <htmlMessage>  
  71.                 <![CDATA[
  72.                     <p>This is a report,testing</p>
  73.                 <br>
  74.                   <p>testing.</p>
  75.                     ]]>  
  76.                 </htmlMessage>  
  77.               </configuration>  
  78.             </execution>  
  79.           </executions>  
  80.         </plugin>  
  81.       </plugins>  
  82.     </build>  
  83.     <reporting>  
  84.       <plugins>  
  85.         <plugin>  
  86.           <groupId>org.apache.maven.plugins</groupId>  
  87.           <artifactId>maven-surefire-report-plugin</artifactId>  
  88.           <version>2.15</version>  
  89.         </plugin>  
  90.       </plugins>  
  91.     </reporting>  
  92.   </project>  

1 comment

POM:

  1. <?xml version="1.0" encoding="UTF-8"?>  
  2. <project xmlns="http://maven.apache.org/POM/4.0.0"  
  3.          xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"  
  4.          xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">  
  5.   <modelVersion>4.0.0</modelVersion>  
  6.   <groupId>TrustOne</groupId>  
  7.   <artifactId>TrustOne</artifactId>  
  8.   <version>1.0</version>  
  9.   <dependencies>  
  10.     <dependency>  
  11.       <groupId>org.seleniumhq.selenium</groupId>  
  12.       <artifactId>selenium-java</artifactId>  
  13.       <version>2.34.0</version>  
  14.     </dependency>  
  15.     <dependency>  
  16.       <groupId>junit</groupId>  
  17.       <artifactId>junit</artifactId>  
  18.       <version>4.11</version>  
  19.       <scope>test</scope>  
  20.     </dependency>  
  21.     <dependency>  
  22.       <groupId>org.apache.maven.surefire</groupId>  
  23.       <artifactId>surefire</artifactId>  
  24.       <version>2.15</version>  
  25.       <type>pom</type>  
  26.     </dependency>  
  27.   </dependencies>  
  28.   <build>  
  29.     <plugins>  
  30.       <plugin>  
  31.         <groupId>org.apache.maven.plugins</groupId>  
  32.         <artifactId>maven-compiler-plugin</artifactId>  
  33.         <version>3.1</version>  
  34.         <configuration>  
  35.           <source>1.7</source>  
  36.           <target>1.7</target>  
  37.         </configuration>  
  38.       </plugin>  
  39.       <plugin>  
  40.         <groupId>org.apache.maven.plugins</groupId>  
  41.         <artifactId>maven-site-plugin</artifactId>  
  42.         <version>3.0-beta-3</version>  
  43.       </plugin>  
  44.       <plugin>  
  45.         <groupId>ch.fortysix</groupId>  
  46.         <artifactId>maven-postman-plugin</artifactId>  
  47.         <version>0.1.6</version>  
  48.         <executions>  
  49.           <execution>  
  50.             <id>send_an_email</id>  
  51.             <phase>deploy</phase>  
  52.             <goals>  
  53.               <goal>send-mail</goal>  
  54.             </goals>  
  55.             <inherited>true</inherited>  
  56.             <configuration>  
  57.               <mailhost>smtp.gmail.com</mailhost>  
  58.               <mailport>995</mailport>  
  59.               <mailssl>true</mailssl>  
  60.               <mailAltConfig>true</mailAltConfig>  
  61.               <mailuser>myemail@gmail.com</mailuser>  
  62.               <mailpassword>password1</mailpassword>  
  63.               <from<davidjsmithers</from>  
  64.               <receivers>  
  65.                 <receiver>myemail@gmail.com</receiver>  
  66.                 <receiver>myemail@gmail.com</receiver>  
  67.               </receivers>  
  68.               <subject>Property Integrity Report</subject>  
  69.               <failonerror>false</failonerror>  
  70.               <htmlMessage>  
  71.                 <![CDATA[
  72.                     <p>This is a report,testing</p>
  73.                 <br>
  74.                   <p>testing.</p>
  75.                     ]]>  
  76.                 </htmlMessage>  
  77.               </configuration>  
  78.             </execution>  
  79.           </executions>  
  80.         </plugin>  
  81.       </plugins>  
  82.     </build>  
  83.     <reporting>  
  84.       <plugins>  
  85.         <plugin>  
  86.           <groupId>org.apache.maven.plugins</groupId>  
  87.           <artifactId>maven-surefire-report-plugin</artifactId>  
  88.           <version>2.15</version>  
  89.         </plugin>  
  90.       </plugins>  
  91.     </reporting>  
  92.   </project>  

0

Please sign in to leave a comment.