I have placed the build.xml file in the same folder as my test script it does produce the xml file after I ran the code but I want the report in html so I have amended the report format to 'frames' and added the style directory but it doesn't work it still just produce the xml file.
<property name="report.dir" value="test\reports" />
<target name="generateReport">
<junitreport todir="${report.dir}">
<fileset dir="${report.dir}">
<include name="*.xml" />
</fileset>`
<report format="frames" styledir="C:\TestFolder\junit-frames.xsl" todir="./report/html" />
</junitreport>
</target>
</project>
styledir parameter must point at the xsl directory, not the single file.
Related
I need to use report data in a project. As of now report is generating in the HTML format. so it is easier if there anyway I can convert it in to a JSON file. Here is my build.xml file:
</fileset>
<report format="frames" todir="D:\API_Testing_Dashboard\SoapProjects\Team Awesome Sauce\ConditionR4\Report">
<param name="TITLE" expression="${junit.configuration} test results." />
</report>
</junitreport>
I'm trying to follow the SSRS documentation to build an Atom-Compliant data feed based off of one of my reports.
Environment: SSRS 2012 Integrated into Sharepoint 2013
Report: Contains Map and Tablix (both should generate data feeds)
I understand that you have to download the atom service document and that it should contain the data feed URL but I'm stuck because the URLs in the service doc do not have an ID like the documentation says that they will. Instead the URL ends with:
Command=Render&rs%3AFormat=ATOM&rc%3AItemPath=Tablix1
Which just runs the report if I try to navigate to this link.
Full service doc:
<?xml version="1.0" encoding="UTF-8"?>
<service xmlns="http://www.w3.org/2007/app" xmlns:app="http://www.w3.org/2007/app" xmlns:atom="http://www.w3.org/2005/Atom">
<workspace>
<atom:title>Countries.rdl</atom:title>
<collection href="https://hr.company.com/dashboards/gwa/_vti_bin/ReportServer?https%3a%2f%2fhr.company.com%2fdashboards%2fgwa%2fexec-DEV%2fReports%2fOverview+Reports%2fCountries.rdl&rs%3ACommand=Render&rs%3AFormat=ATOM&rc%3AItemPath=Map2.Map2_PolygonLayer1_Group">
<atom:title>Map2</atom:title>
</collection>
<collection href="https://hr.company.com/dashboards/gwa/_vti_bin/ReportServer?https%3a%2f%2fhr.company.com%2fdashboards%2fgwa%2fexec-DEV%2fReports%2fOverview+Reports%2fCountries.rdl&rs%3ACommand=Render&rs%3AFormat=ATOM&rc%3AItemPath=Tablix1">
<atom:title>Tablix1</atom:title>
</collection>
</workspace>
</service>
How can I generate the Atom Feed ID????
It appears that there isn't an atom identifier due to the fact that there is no device setting for ATOM in rsreportserver.config file.
We have a problem downloading .json files via IIS7.5.
MIME type has been set correctly:
<mimeMap fileExtension=".json " mimeType="application/json" />
But still gives error: "HTTP Error 404.3 - Not Found".
To get it to work we have to add a handler mapping:
<handlers>
<add name="JSON" path="*.json" verb="*" modules="IsapiModule" scriptProcessor="C:\WINDOWS\system32\inetsrv\asp.dll" resourceType="Unspecified" />
</handlers>
Why can't json files be handled by the StaticFileHandler like other static content? It seems bizarre we have to install classic asp support to handle json files.
In my case a StaticFileHandler does handle json by itself. The asp.dll handler is not required.
Problem was a sneaky trailing space in the fileExtension property:
<mimeMap fileExtension=".json " mimeType="application/json" />
doh
Recently I ran into this problem too. First I added the .json MIME type. But I had placed my json file in the app_data folder. If you don't give the web application rights to that folder it won't work.
Try putting your json file in the same folder as the html file.
Also, the Mapping Handler won't work unless you have installed the Classic Asp module (in Windows Features). I've written some full directions here.
Anyone know how to inject an ant build date time stamp into an html page?
When you refer ant, I assume you're on Java.
You can use tstamp task and echo to a property file. This property file can be bundled into the jar so that the application can read the property and display the value as required.
Ex:
<target name="build.timestamp">
<tstamp>
<format property="build.timestamp" pattern="yyyy.MM.dd-hh.mm.ss" locale="en,UK"/>
</tstamp>
<echo message="tstamp=${build.timestamp}" file="build-timestamp.properties"/>
</target>
This will create a build-timestamp.properties in current ant directory.
Jar it up as a regular resource file along with application classes so that it becomes available at app run time.
I have simple java app that prints `hello world!' on console. It is packed in app.jar.
Jar structure:
main/Hello.class - my main class with singe println method
META-INF/MANIFEST.MF
Manifest file contains following:
Manifest-Version: 1.0
Main-Class: main.Hello
Everything goes fine.
But when you have a dependency than troubles begin. I'm not sure but think in this case you have to put all libs to jar file. If I put them in META-INF/lib I must specify "Class-Path" in manifest. How "Class-Path" will look?
P.S There are some resembling questions but I haven't found appropriate answer.
I tend to use an ANT build script to package my application and all necessary jar files. I find this makes life much easier once you've got it working properly.
build.xml file looks something like:
<project default="create_run_jar" name="Create Runnable Jar for MyProject">
<!--ANT 1.7 is required -->
<target name="create_run_jar">
<jar destfile="my-runnable-jar.jar">
<manifest>
<attribute name="Main-Class" value="my.MainClass"/>
<attribute name="Class-Path" value="."/>
</manifest>
<fileset dir="E:/path/to/my/project/bin"/>
<fileset dir="E:/path/to/my/project/classes"/>
<zipfileset src="E:/path/to/library/some-library.jar"/>
</jar>
</target>
</project>
Note that if you use Eclipse, you can simplly do File / Export... / Runnable jar file and it will do everything for you (including generating the ANT build.xml).
You don't have to specify anything special if you unpack the libraries and integrate them into your project. If you do this, you should have a "main" folder, and if you have org.apache.foo as an external library, you'll also have an "org" folder at the top level.