[Sciviews-commits] r333 - in pkg/svUnit: . R inst/doc
noreply at r-forge.r-project.org
noreply at r-forge.r-project.org
Fri Oct 15 09:09:46 CEST 2010
Author: mariotomo
Date: 2010-10-15 09:09:46 +0200 (Fri, 15 Oct 2010)
New Revision: 333
Modified:
pkg/svUnit/DESCRIPTION
pkg/svUnit/NEWS
pkg/svUnit/R/svTestData.R
pkg/svUnit/inst/doc/svUnit.pdf
Log:
#1147: encoding entities in attribute "message".
Modified: pkg/svUnit/DESCRIPTION
===================================================================
--- pkg/svUnit/DESCRIPTION 2010-10-13 16:09:45 UTC (rev 332)
+++ pkg/svUnit/DESCRIPTION 2010-10-15 07:09:46 UTC (rev 333)
@@ -4,7 +4,7 @@
Depends: R (>= 1.9.0)
Suggests: svGUI, datasets, utils, XML
Description: A complete unit test system and functions to implement its GUI part
-Version: 0.7-4
+Version: 0.7-5
Date: 2010-09-30
Author: Philippe Grosjean
Maintainer: Philippe Grosjean <phgrosjean at sciviews.org>
Modified: pkg/svUnit/NEWS
===================================================================
--- pkg/svUnit/NEWS 2010-10-13 16:09:45 UTC (rev 332)
+++ pkg/svUnit/NEWS 2010-10-15 07:09:46 UTC (rev 333)
@@ -1,5 +1,9 @@
= svUnit News
+== svUnit 0.7-5
+
+* XML-encoding entities in protocol_junit.svTestData. closes #1147
+
== svUnit 0.7-4
* Backquoting of test name in evaluation instruction, allowing to use
Modified: pkg/svUnit/R/svTestData.R
===================================================================
--- pkg/svUnit/R/svTestData.R 2010-10-13 16:09:45 UTC (rev 332)
+++ pkg/svUnit/R/svTestData.R 2010-10-15 07:09:46 UTC (rev 333)
@@ -90,7 +90,13 @@
if(!require(XML, quietly=TRUE))
return(invisible(FALSE))
- toValidXmlString <- function(s) gsub("<", "<", s)
+ toValidXmlString <- function(s) {
+ s <- gsub("<", "<", s)
+ s <- gsub(">", ">", s)
+ s <- gsub('"', """, s)
+ s <- gsub("'", "'", s)
+ gsub("&", "&", s)
+ }
basename <- function(s) sub(".*/", "", s)
@@ -107,7 +113,7 @@
failureNode <- xmlNode(elementName,
attrs=c(
'type'=elementName,
- 'message'=object$res)) # TODO: use accessor
+ 'message'=toValidXmlString(object$res))) # TODO: use accessor
result <- addChildren(result, kids=list(failureNode))
}
if(kind == 4)
Modified: pkg/svUnit/inst/doc/svUnit.pdf
===================================================================
(Binary files differ)
More information about the Sciviews-commits
mailing list