You can subscribe to this list here.
| 2003 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(142) |
Jun
(27) |
Jul
(122) |
Aug
(36) |
Sep
(59) |
Oct
(86) |
Nov
(140) |
Dec
(80) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2004 |
Jan
(52) |
Feb
(153) |
Mar
(118) |
Apr
(143) |
May
(123) |
Jun
(64) |
Jul
(282) |
Aug
(469) |
Sep
(56) |
Oct
(201) |
Nov
(182) |
Dec
(31) |
| 2005 |
Jan
(229) |
Feb
(316) |
Mar
(187) |
Apr
(130) |
May
(190) |
Jun
(154) |
Jul
(148) |
Aug
(133) |
Sep
(209) |
Oct
(234) |
Nov
(100) |
Dec
(40) |
| 2006 |
Jan
(1) |
Feb
(87) |
Mar
(73) |
Apr
(126) |
May
(58) |
Jun
(8) |
Jul
(12) |
Aug
(14) |
Sep
(22) |
Oct
(33) |
Nov
(4) |
Dec
|
| S | M | T | W | T | F | S |
|---|---|---|---|---|---|---|
|
|
|
|
|
|
|
1
|
|
2
|
3
|
4
|
5
|
6
(9) |
7
(5) |
8
|
|
9
(9) |
10
(6) |
11
(13) |
12
|
13
|
14
|
15
|
|
16
|
17
|
18
|
19
(24) |
20
(2) |
21
(7) |
22
|
|
23
|
24
|
25
|
26
(1) |
27
(36) |
28
(14) |
29
|
|
30
|
|
|
|
|
|
|
|
From: Ashish <ash...@us...> - 2006-04-28 16:53:37
|
Update of /cvsroot/ccnet/ccnet/project/xsl In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv12916/project/xsl Modified Files: statistics.xsl Log Message: CCNET-642: Formatting Index: statistics.xsl =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/xsl/statistics.xsl,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** statistics.xsl 28 Apr 2006 16:09:26 -0000 1.5 --- statistics.xsl 28 Apr 2006 16:53:32 -0000 1.6 *************** *** 49,52 **** --- 49,53 ---- </table> </p> + <p><pre><strong>Note: </strong>Only builds run with the statistics publisher enabled will appear on this page!</pre></p> <table> <tr> |
|
From: Ashish <ash...@us...> - 2006-04-28 16:09:30
|
Update of /cvsroot/ccnet/ccnet/project/xsl In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv9709/project/xsl Modified Files: statistics.xsl Log Message: CCNET-642: Formatting Index: statistics.xsl =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/xsl/statistics.xsl,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** statistics.xsl 28 Apr 2006 09:01:36 -0000 1.4 --- statistics.xsl 28 Apr 2006 16:09:26 -0000 1.5 *************** *** 33,47 **** </tr> <tr> ! <th>Total Builds</th> <td><xsl:value-of select="$totalCountForTheDay"/></td> <td><xsl:value-of select="$totalCount"/></td> </tr> <tr> ! <th>Number of Successful</th> <td><xsl:value-of select="$successCountForTheDay"/></td> <td><xsl:value-of select="$successCount"/></td> </tr> <tr> ! <th>Number of Failed</th> <td><xsl:value-of select="$failureCountForTheDay"/></td> <td><xsl:value-of select="$failureCount"/></td> --- 33,47 ---- </tr> <tr> ! <th align="left">Total Builds</th> <td><xsl:value-of select="$totalCountForTheDay"/></td> <td><xsl:value-of select="$totalCount"/></td> </tr> <tr> ! <th align="left">Number of Successful</th> <td><xsl:value-of select="$successCountForTheDay"/></td> <td><xsl:value-of select="$successCount"/></td> </tr> <tr> ! <th align="left">Number of Failed</th> <td><xsl:value-of select="$failureCountForTheDay"/></td> <td><xsl:value-of select="$failureCount"/></td> |
|
From: Ashish <ash...@us...> - 2006-04-28 10:40:23
|
Update of /cvsroot/ccnet/ccnet/project/core/publishers/Statistics In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv16284/project/core/publishers/Statistics Modified Files: StatisticsPublisher.cs Log Message: CCNET-642: Added a configurable attribute on Project for Statistics File. Need to check why its not working, always picks up the default value Index: StatisticsPublisher.cs =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/core/publishers/Statistics/StatisticsPublisher.cs,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** StatisticsPublisher.cs 28 Apr 2006 10:39:24 -0000 1.7 --- StatisticsPublisher.cs 28 Apr 2006 10:40:07 -0000 1.8 *************** *** 57,61 **** xml.SetAttribute("month", now.ToString("MMM")); xml.SetAttribute("year", now.Year.ToString()); - xml.SetAttribute("fileName", integrationResult.StatisticsFile); root.AppendChild(xml); --- 57,60 ---- |
|
From: Ashish <ash...@us...> - 2006-04-28 10:39:37
|
Update of /cvsroot/ccnet/ccnet/project/UnitTests In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv15415/project/UnitTests Modified Files: UnitTests.csproj Log Message: CCNET-642: Added a configurable attribute on Project for Statistics File. Need to check why its not working, always picks up the default value Index: UnitTests.csproj =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/UnitTests/UnitTests.csproj,v retrieving revision 1.174 retrieving revision 1.175 diff -C2 -d -r1.174 -r1.175 *** UnitTests.csproj 27 Apr 2006 06:20:50 -0000 1.174 --- UnitTests.csproj 28 Apr 2006 10:39:24 -0000 1.175 *************** *** 687,696 **** /> <File ! RelPath = "Core\Publishers\Statistics\StatisticsChartGeneratorTest.cs" SubType = "Code" BuildAction = "Compile" /> <File ! RelPath = "Core\Publishers\Statistics\StatisticsPublisherTaskTest.cs" SubType = "Code" BuildAction = "Compile" --- 687,696 ---- /> <File ! RelPath = "Core\Publishers\Statistics\StatisticsBuilderTest.cs" SubType = "Code" BuildAction = "Compile" /> <File ! RelPath = "Core\Publishers\Statistics\StatisticsChartGeneratorTest.cs" SubType = "Code" BuildAction = "Compile" |
|
From: Ashish <ash...@us...> - 2006-04-28 10:39:37
|
Update of /cvsroot/ccnet/ccnet/project/UnitTests/Core/Publishers/Statistics In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv15415/project/UnitTests/Core/Publishers/Statistics Modified Files: StatisticsPublisherTest.cs Added Files: StatisticsBuilderTest.cs Removed Files: StatisticsPublisherTaskTest.cs Log Message: CCNET-642: Added a configurable attribute on Project for Statistics File. Need to check why its not working, always picks up the default value --- NEW FILE: StatisticsBuilderTest.cs --- using System; using System.Collections; using System.IO; using System.Xml; using NUnit.Framework; using ThoughtWorks.CruiseControl.Core; using ThoughtWorks.CruiseControl.Core.Publishers; using ThoughtWorks.CruiseControl.Core.Publishers.Statistics; namespace ThoughtWorks.CruiseControl.UnitTests.Core.Publishers.Statistics { [TestFixture] public class StatisticsBuilderTest : XmlLogFixture { private const string outDir = "temp"; private StatisticsBuilder builder; IntegrationResult result; private string xml; [TestFixtureSetUp] public void LoadXML() { StreamReader reader = File.OpenText("buildlog.xml"); xml = reader.ReadToEnd(); reader.Close(); } [SetUp] public void SetUp() { builder = new StatisticsBuilder(); result = IntegrationResultMother.Create(true); Directory.CreateDirectory(outDir); } private string xmlResult() { return toXml(result); } private string toXml(IIntegrationResult result) { StringWriter xmlResultString = new StringWriter(); XmlIntegrationResultWriter writer = new XmlIntegrationResultWriter(xmlResultString); writer.Write(result); return xmlResultString.ToString(); } [TearDown] public void TearDown() { Directory.Delete("temp", true); } public void AssertHasStatistic(string name, object value) { Assert.AreEqual(value, builder.Statistic(name), "Wrong statistic for {0}", name); } [Test] public void ShouldPopulateNUnitSummaryFromLog() { string xml = @"<task> <test-results total=""6"" failures=""1"" not-run=""2"" date=""2005-04-29"" time=""9:02 PM""> <test-suite /> </test-results> <test-results total=""1"" failures=""1"" not-run=""1"" date=""2005-04-29"" time=""9:02 PM""> <test-suite /> </test-results> </task>"; result.AddTaskResult(xml); builder.ProcessBuildResults(xmlResult()); AssertHasStatistic("TestCount", 7); AssertHasStatistic("TestFailures", 2); AssertHasStatistic("TestIgnored", 3); } [Test] public void ShouldCollectFxCopStatistics() { builder.ProcessBuildResults(xml); AssertHasStatistic("FxCop Warnings", 1); AssertHasStatistic("FxCop Errors", 205); } [Test] public void ShouldPopulateTimingsFromIntegrationResult() { result.StartTime = new DateTime(2005, 03, 12, 01, 13, 00); result.EndTime = new DateTime(2005, 03, 12, 01, 45, 00); result.ProjectName = "Foo"; builder.ProcessBuildResults(xmlResult()); AssertHasStatistic("StartTime", result.StartTime.ToString()); AssertHasStatistic("Duration", new TimeSpan(0, 32, 0).ToString()); AssertHasStatistic("ProjectName", "Foo"); } [Test] public void ShouldWriteStatisticsAsXml() { builder.ProcessBuildResults(xmlResult()); StringWriter writer = new StringWriter(); builder.Save(writer); string xml = writer.ToString(); AssertXPath(xml, "//statistics/statistic/@name", "ProjectName"); } private void AssertXPath(string xml, string xpath, string expectedValue) { XmlDocument doc = new XmlDocument(); doc.LoadXml(xml); XmlNodeList node = doc.SelectNodes(xpath); ArrayList actuals = new ArrayList(); foreach (XmlNode n in node) { string actual = n.Value; actuals.Add(actual); if (actual == expectedValue) return; } Assert.Fail("No node found matching {0}. Actuals were {1}", expectedValue, actuals); } } } --- StatisticsPublisherTaskTest.cs DELETED --- Index: StatisticsPublisherTest.cs =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/UnitTests/Core/Publishers/Statistics/StatisticsPublisherTest.cs,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** StatisticsPublisherTest.cs 19 Apr 2006 23:31:06 -0000 1.3 --- StatisticsPublisherTest.cs 28 Apr 2006 10:39:24 -0000 1.4 *************** *** 1,9 **** - using System; - using System.Collections; using System.IO; using System.Xml; using NUnit.Framework; using ThoughtWorks.CruiseControl.Core; - using ThoughtWorks.CruiseControl.Core.Publishers; using ThoughtWorks.CruiseControl.Core.Publishers.Statistics; --- 1,6 ---- *************** *** 11,133 **** { [TestFixture] ! public class StatisticsBuilderTest : XmlLogFixture { ! private const string outDir = "temp"; ! private StatisticsBuilder builder; ! IntegrationResult result; ! private string xml; ! ! [TestFixtureSetUp] ! public void LoadXML() ! { ! StreamReader reader = File.OpenText("buildlog.xml"); ! xml = reader.ReadToEnd(); ! reader.Close(); ! } [SetUp] ! public void SetUp() ! { ! builder = new StatisticsBuilder(); ! result = IntegrationResultMother.Create(true); ! Directory.CreateDirectory(outDir); ! } ! ! ! private string xmlResult() ! { ! return toXml(result); ! } ! ! private string toXml(IIntegrationResult result) { ! StringWriter xmlResultString = new StringWriter(); ! XmlIntegrationResultWriter writer = new XmlIntegrationResultWriter(xmlResultString); ! writer.Write(result); ! return xmlResultString.ToString(); } [TearDown] ! public void TearDown() ! { ! Directory.Delete("temp", true); ! } ! ! public void AssertHasStatistic(string name, object value) { ! Assert.AreEqual(value, builder.Statistic(name), "Wrong statistic for {0}", name); } [Test] ! public void ShouldPopulateNUnitSummaryFromLog() { ! string xml = ! @"<task> ! <test-results total=""6"" failures=""1"" not-run=""2"" date=""2005-04-29"" time=""9:02 PM""> ! <test-suite /> ! </test-results> ! <test-results total=""1"" failures=""1"" not-run=""1"" date=""2005-04-29"" time=""9:02 PM""> ! <test-suite /> ! </test-results> ! </task>"; ! result.AddTaskResult(xml); ! builder.ProcessBuildResults(xmlResult()); ! AssertHasStatistic("TestCount", 7); ! AssertHasStatistic("TestFailures", 2); ! AssertHasStatistic("TestIgnored", 3); } [Test] ! public void ShouldCollectFxCopStatistics() { ! builder.ProcessBuildResults(xml); ! AssertHasStatistic("FxCop Warnings", 1); ! AssertHasStatistic("FxCop Errors", 205); ! } ! [Test] ! public void ShouldPopulateTimingsFromIntegrationResult() ! { ! result.StartTime = new DateTime(2005, 03, 12, 01, 13, 00); ! result.EndTime = new DateTime(2005, 03, 12, 01, 45, 00); ! result.ProjectName = "Foo"; ! builder.ProcessBuildResults(xmlResult()); ! AssertHasStatistic("StartTime", result.StartTime.ToString()); ! AssertHasStatistic("Duration", new TimeSpan(0, 32, 0).ToString()); ! AssertHasStatistic("ProjectName", "Foo"); } ! [Test] ! public void ShouldWriteStatisticsAsXml() { ! builder.ProcessBuildResults(xmlResult()); ! StringWriter writer = new StringWriter(); ! builder.Save(writer); ! string xml = writer.ToString(); ! AssertXPath(xml, "//statistics/statistic/@name", "ProjectName"); } ! private void AssertXPath(string xml, string xpath, string expectedValue) { ! XmlDocument doc = new XmlDocument(); ! doc.LoadXml(xml); ! XmlNodeList node = doc.SelectNodes(xpath); ! ArrayList actuals = new ArrayList(); ! foreach (XmlNode n in node) { ! string actual = n.Value; ! actuals.Add(actual); ! if (actual == expectedValue) return; } ! Assert.Fail("No node found matching {0}. Actuals were {1}", expectedValue, actuals); } } --- 8,107 ---- { [TestFixture] ! public class StatisticsPublisherTest { ! const string TEST_DIR = "build\\temp"; ! private DirectoryInfo tmpdir; [SetUp] ! public void CreateFakeOutputDir() { ! if (Directory.Exists(TEST_DIR)) ! { ! Directory.Delete(TEST_DIR, true); ! } ! tmpdir = Directory.CreateDirectory(TEST_DIR); } [TearDown] ! public void DeleteTempDirectory() { ! if (Directory.Exists(TEST_DIR)) ! { ! Directory.Delete(TEST_DIR, true); ! } } [Test] ! public void CreatesStatisticsFileInArtifactDirectory() { ! IntegrationResult result1 = simulateBuild(1); ! string statsFile = result1.ArtifactDirectory + "\\statistics.xml"; ! Assert.IsTrue(File.Exists(statsFile)); ! CountNodes(statsFile, "//statistics/integration", 1); ! IntegrationResult result2 = simulateBuild(2); ! ! string statsFile2 = result2.ArtifactDirectory + "\\statistics.xml"; ! Assert.IsTrue(File.Exists(statsFile2)); ! ! CountNodes(statsFile2, "//statistics/integration", 2); } [Test] ! public void CreatesCsvFileInArtifactsDirectory() { ! IntegrationResult result1 = simulateBuild(1); ! string statsFile = result1.ArtifactDirectory + "\\statistics.csv"; ! Assert.IsTrue(File.Exists(statsFile)); ! CountLines(statsFile, 2); ! IntegrationResult result2 = simulateBuild(2); ! string statsFile2 = result2.ArtifactDirectory + "\\statistics.csv"; ! Assert.IsTrue(File.Exists(statsFile2)); ! CountLines(statsFile2, 3); } ! private IntegrationResult simulateBuild(int buildLabel) { ! StatisticsPublisher publisher = new StatisticsPublisher(); ! ! IntegrationResult result = IntegrationResultMother.CreateSuccessful(buildLabel.ToString()); ! result.LastSuccessfulIntegrationLabel = (buildLabel - 1).ToString(); ! result.ArtifactDirectory = tmpdir.FullName; ! result.StatisticsFile = "statistics.xml"; ! ! publisher.Run(result); ! ! return result; } ! private void CountLines(string file, int expectedCount) { ! StreamReader text = File.OpenText(file); ! string s = text.ReadToEnd(); ! string[] split = s.Split('\n'); ! int count = 0; ! foreach(string line in split) { ! if (line.Length>0) count++; } ! Assert.AreEqual(expectedCount, count); ! text.Close(); ! } ! ! private static void CountNodes(string statsFile2, string xpath, int count) ! { ! XmlDocument doc = new XmlDocument(); ! doc.Load(statsFile2); ! XmlNodeList node = doc.SelectNodes(xpath); ! Assert.AreEqual(count, node.Count); } } |
|
From: Ashish <ash...@us...> - 2006-04-28 10:39:37
|
Update of /cvsroot/ccnet/ccnet/project/core In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv15415/project/core Modified Files: IIntegrationResult.cs IIntegrationRunnerTarget.cs IntegrationResult.cs IntegrationResultManager.cs Project.cs Log Message: CCNET-642: Added a configurable attribute on Project for Statistics File. Need to check why its not working, always picks up the default value Index: IntegrationResult.cs =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/core/IntegrationResult.cs,v retrieving revision 1.43 retrieving revision 1.44 diff -C2 -d -r1.43 -r1.44 *** IntegrationResult.cs 9 Apr 2006 16:44:25 -0000 1.43 --- IntegrationResult.cs 28 Apr 2006 10:39:24 -0000 1.44 *************** *** 49,52 **** --- 49,58 ---- } + public IntegrationResult(string projectName, string workingDirectory, + string statisticsFile, IntegrationRequest request) : this(projectName, workingDirectory, request) + { + StatisticsFile = statisticsFile; + } + // remove setter public string ProjectName *************** *** 86,89 **** --- 92,101 ---- } + public string StatisticsFile + { + get { return (string) properties["ProjectStatisticsFile"]; } + set { properties["ProjectStatisticsFile"] = value; } + } + public string IntegrationArtifactDirectory { Index: IIntegrationRunnerTarget.cs =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/core/IIntegrationRunnerTarget.cs,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** IIntegrationRunnerTarget.cs 10 Sep 2005 19:01:28 -0000 1.3 --- IIntegrationRunnerTarget.cs 28 Apr 2006 10:39:24 -0000 1.4 *************** *** 13,16 **** // Would like to have this somewhere else really ProjectActivity Activity { set; } } ! } --- 13,18 ---- // Would like to have this somewhere else really ProjectActivity Activity { set; } + + string StatisticsFile { get; set; } } ! } \ No newline at end of file Index: IntegrationResultManager.cs =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/core/IntegrationResultManager.cs,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** IntegrationResultManager.cs 25 Mar 2006 00:32:19 -0000 1.7 --- IntegrationResultManager.cs 28 Apr 2006 10:39:24 -0000 1.8 *************** *** 30,34 **** public IIntegrationResult StartNewIntegration(IntegrationRequest request) { ! currentResult = new IntegrationResult(project.Name, project.WorkingDirectory, request); currentResult.LastIntegrationStatus = LastIntegrationResult.Status; --- 30,34 ---- public IIntegrationResult StartNewIntegration(IntegrationRequest request) { ! currentResult = new IntegrationResult(project.Name, project.WorkingDirectory, project.StatisticsFile, request); currentResult.LastIntegrationStatus = LastIntegrationResult.Status; Index: IIntegrationResult.cs =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/core/IIntegrationResult.cs,v retrieving revision 1.14 retrieving revision 1.15 diff -C2 -d -r1.14 -r1.15 *** IIntegrationResult.cs 9 Apr 2006 16:44:25 -0000 1.14 --- IIntegrationResult.cs 28 Apr 2006 10:39:24 -0000 1.15 *************** *** 18,21 **** --- 18,22 ---- TimeSpan TotalIntegrationTime { get; } string ArtifactDirectory { get; set;} + string StatisticsFile {get; set;} bool Failed { get; } bool Fixed { get; } Index: Project.cs =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/core/Project.cs,v retrieving revision 1.70 retrieving revision 1.71 diff -C2 -d -r1.70 -r1.71 *** Project.cs 28 Apr 2006 09:01:36 -0000 1.70 --- Project.cs 28 Apr 2006 10:39:24 -0000 1.71 *************** *** 36,40 **** { private string webUrl = DefaultUrl(); ! private string statisticsFile = "statistics.xml"; private ISourceControl sourceControl = new NullSourceControl(); private ITask builder = new NullTask(); --- 36,40 ---- { private string webUrl = DefaultUrl(); ! private string statisticsFile = "report.xml"; private ISourceControl sourceControl = new NullSourceControl(); private ITask builder = new NullTask(); *************** *** 82,85 **** --- 82,92 ---- } + [ReflectorProperty("statisticsFile", Required=false)] + public string StatisticsFile + { + get { return statisticsFile; } + set { statisticsFile = value; } + } + [ReflectorProperty("sourcecontrol", InstanceTypeKey="type", Required=false)] public ISourceControl SourceControl *************** *** 210,220 **** } - [ReflectorProperty("statisticsFile", Required=false)] - public string StatisticsFile - { - get { return statisticsFile; } - set { statisticsFile = value; } - } - public XmlDocument Statistics { --- 217,220 ---- |
|
From: Ashish <ash...@us...> - 2006-04-28 10:39:31
|
Update of /cvsroot/ccnet/ccnet/project/core/publishers/Statistics In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv15415/project/core/publishers/Statistics Modified Files: StatisticsPublisher.cs Log Message: CCNET-642: Added a configurable attribute on Project for Statistics File. Need to check why its not working, always picks up the default value Index: StatisticsPublisher.cs =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/core/publishers/Statistics/StatisticsPublisher.cs,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** StatisticsPublisher.cs 28 Apr 2006 09:01:36 -0000 1.6 --- StatisticsPublisher.cs 28 Apr 2006 10:39:24 -0000 1.7 *************** *** 13,17 **** public class StatisticsPublisher : ITask { - private static string xmlFileName = "statistics.xml"; private static string csvFileName = "statistics.csv"; --- 13,16 ---- *************** *** 58,61 **** --- 57,61 ---- xml.SetAttribute("month", now.ToString("MMM")); xml.SetAttribute("year", now.Year.ToString()); + xml.SetAttribute("fileName", integrationResult.StatisticsFile); root.AppendChild(xml); *************** *** 82,86 **** private string XmlStatisticsFile(IIntegrationResult integrationResult) { ! return Path.Combine(integrationResult.ArtifactDirectory, xmlFileName); } --- 82,86 ---- private string XmlStatisticsFile(IIntegrationResult integrationResult) { ! return Path.Combine(integrationResult.ArtifactDirectory, integrationResult.StatisticsFile); } |
|
From: Ashish <ash...@us...> - 2006-04-28 09:15:28
|
Update of /cvsroot/ccnet/ccnet/project/UnitTests/Core In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv2521/project/UnitTests/Core Modified Files: CruiseServerTest.cs Log Message: Added test for CruiseServer.GetStatisticsDocument Index: CruiseServerTest.cs =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/UnitTests/Core/CruiseServerTest.cs,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** CruiseServerTest.cs 28 Apr 2006 09:01:36 -0000 1.7 --- CruiseServerTest.cs 28 Apr 2006 09:15:25 -0000 1.8 *************** *** 2,5 **** --- 2,6 ---- using System.Threading; using System.Xml; + using System.Xml.XPath; using NMock; using NUnit.Framework; *************** *** 326,339 **** fromServer.LoadXml(statisticsDocument); Assert.AreEqual(statisticsClone.DocumentElement.ChildNodes.Count + 1, fromServer.DocumentElement.ChildNodes.Count); ! // XPathNavigator navigator = fromServer.CreateNavigator(); ! // object o = navigator.Evaluate("/statistics//timestamp/@day"); ! // string s = o.ToString(); ! // int day = (int) o; ! // int month = (int) navigator.Evaluate("/statistics//timestamp/@month"); ! // int year = (int) navigator.Evaluate("/statistics//timestamp/@year"); ! // ! // Assert.AreEqual(DateTime.Now.Day, day); ! // Assert.AreEqual(DateTime.Now.Month, month); ! // Assert.AreEqual(DateTime.Now.Year, year); } } --- 327,349 ---- fromServer.LoadXml(statisticsDocument); Assert.AreEqual(statisticsClone.DocumentElement.ChildNodes.Count + 1, fromServer.DocumentElement.ChildNodes.Count); ! XPathNavigator navigator = fromServer.CreateNavigator(); ! XPathNodeIterator nodeIterator = navigator.Select("//timestamp/@day"); ! if(nodeIterator.MoveNext()) ! { ! int day = Convert.ToInt32(nodeIterator.Current.Value); ! Assert.AreEqual(DateTime.Now.Day, day); ! } ! nodeIterator = navigator.Select("//timestamp/@month"); ! if(nodeIterator.MoveNext()) ! { ! string month = nodeIterator.Current.Value; ! Assert.AreEqual(DateTime.Now.ToString("MMM"), month); ! } ! nodeIterator = navigator.Select("//timestamp/@year"); ! if(nodeIterator.MoveNext()) ! { ! int year = Convert.ToInt32(nodeIterator.Current.Value); ! Assert.AreEqual(DateTime.Now.Year, year); ! } } } |
|
From: Ashish <ash...@us...> - 2006-04-28 09:01:42
|
Update of /cvsroot/ccnet/ccnet/project/core In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv22317/project/core Modified Files: CruiseServer.cs IProject.cs Project.cs Workflow.cs Log Message: CCNET-642: Added XmlDocument Statistics { get; } to IProject. Sending the current date as part of the statistics document from server. This information is used for generating a daily and overall build summary for now. Index: CruiseServer.cs =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/core/CruiseServer.cs,v retrieving revision 1.45 retrieving revision 1.46 diff -C2 -d -r1.45 -r1.46 *** CruiseServer.cs 27 Apr 2006 15:14:58 -0000 1.45 --- CruiseServer.cs 28 Apr 2006 09:01:36 -0000 1.46 *************** *** 362,368 **** public string GetStatisticsDocument(string projectName) { ! string artifactDirectory = GetIntegrator(projectName).Project.ArtifactDirectory; ! XmlDocument xmlDocument = new XmlDocument(); ! xmlDocument.Load(Path.Combine(artifactDirectory, "statistics.xml")); return xmlDocument.OuterXml; } --- 362,374 ---- public string GetStatisticsDocument(string projectName) { ! IProject project = GetIntegrator(projectName).Project; ! XmlDocument xmlDocument = project.Statistics; ! XmlElement timeStamp = xmlDocument.CreateElement("timestamp"); ! DateTime now = DateTime.Now; ! timeStamp.SetAttribute("day", now.Day.ToString()); ! timeStamp.SetAttribute("month", now.ToString("MMM")); ! timeStamp.SetAttribute("year", now.Year.ToString()); ! xmlDocument.DocumentElement.AppendChild(timeStamp); ! return xmlDocument.OuterXml; } Index: IProject.cs =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/core/IProject.cs,v retrieving revision 1.25 retrieving revision 1.26 diff -C2 -d -r1.25 -r1.26 *** IProject.cs 27 Apr 2006 15:14:58 -0000 1.25 --- IProject.cs 28 Apr 2006 09:01:36 -0000 1.26 *************** *** 1,2 **** --- 1,3 ---- + using System.Xml; using ThoughtWorks.CruiseControl.Remote; *************** *** 56,59 **** --- 57,61 ---- ExternalLink[] ExternalLinks { get; } + XmlDocument Statistics { get; } void Initialize(); ProjectStatus CreateProjectStatus(IProjectIntegrator integrator); Index: Workflow.cs =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/core/Workflow.cs,v retrieving revision 1.16 retrieving revision 1.17 diff -C2 -d -r1.16 -r1.17 *** Workflow.cs 27 Apr 2006 15:14:58 -0000 1.16 --- Workflow.cs 28 Apr 2006 09:01:36 -0000 1.17 *************** *** 1,4 **** --- 1,5 ---- using System; using System.Collections; + using System.Xml; using Exortech.NetReflector; using ThoughtWorks.CruiseControl.Remote; *************** *** 71,74 **** --- 72,80 ---- } + public XmlDocument Statistics + { + get { throw new NotImplementedException(); } + } + public void Initialize() { Index: Project.cs =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/core/Project.cs,v retrieving revision 1.69 retrieving revision 1.70 diff -C2 -d -r1.69 -r1.70 *** Project.cs 27 Apr 2006 15:14:58 -0000 1.69 --- Project.cs 28 Apr 2006 09:01:36 -0000 1.70 *************** *** 3,6 **** --- 3,7 ---- using System.ComponentModel; using System.IO; + using System.Xml; using Exortech.NetReflector; using ThoughtWorks.CruiseControl.Core.Label; *************** *** 35,38 **** --- 36,40 ---- { private string webUrl = DefaultUrl(); + private string statisticsFile = "statistics.xml"; private ISourceControl sourceControl = new NullSourceControl(); private ITask builder = new NullTask(); *************** *** 208,211 **** --- 210,231 ---- } + [ReflectorProperty("statisticsFile", Required=false)] + public string StatisticsFile + { + get { return statisticsFile; } + set { statisticsFile = value; } + } + + public XmlDocument Statistics + { + get + { + XmlDocument xmlDocument = new XmlDocument(); + xmlDocument.Load(Path.Combine(ArtifactDirectory, statisticsFile)); + + return xmlDocument; + } + } + public static string DefaultUrl() { |
|
From: Ashish <ash...@us...> - 2006-04-28 09:01:40
|
Update of /cvsroot/ccnet/ccnet/project/core/publishers/Statistics In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv22317/project/core/publishers/Statistics Modified Files: StatisticsPublisher.cs Log Message: CCNET-642: Added XmlDocument Statistics { get; } to IProject. Sending the current date as part of the statistics document from server. This information is used for generating a daily and overall build summary for now. Index: StatisticsPublisher.cs =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/core/publishers/Statistics/StatisticsPublisher.cs,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** StatisticsPublisher.cs 27 Apr 2006 08:12:44 -0000 1.5 --- StatisticsPublisher.cs 28 Apr 2006 09:01:36 -0000 1.6 *************** *** 1,2 **** --- 1,3 ---- + using System; using System.Collections; using System.IO; *************** *** 53,56 **** --- 54,61 ---- IntegrationStatus status = integrationResult.Status; xml.SetAttribute("status", status.ToString()); + DateTime now = DateTime.Now; + xml.SetAttribute("day", now.Day.ToString()); + xml.SetAttribute("month", now.ToString("MMM")); + xml.SetAttribute("year", now.Year.ToString()); root.AppendChild(xml); |
|
From: Ashish <ash...@us...> - 2006-04-28 09:01:40
|
Update of /cvsroot/ccnet/ccnet/project/xsl In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv22317/project/xsl Modified Files: statistics.xsl Log Message: CCNET-642: Added XmlDocument Statistics { get; } to IProject. Sending the current date as part of the statistics document from server. This information is used for generating a daily and overall build summary for now. Index: statistics.xsl =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/xsl/statistics.xsl,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** statistics.xsl 27 Apr 2006 08:12:44 -0000 1.3 --- statistics.xsl 28 Apr 2006 09:01:36 -0000 1.4 *************** *** 5,18 **** <style> *.pass{ ! background-color: green; } *.fail{ ! background-color: red; } *.unknown{ ! background-color: yellow; } </style> ! <table> <tr> --- 5,52 ---- <style> *.pass{ ! background-color: #33ff99; } *.fail{ ! background-color: #ff6600; } *.unknown{ ! background-color: #ffffcc; } </style> ! <p> ! Today is ! <xsl:variable name="day" select="//timestamp/@day"/> ! <xsl:variable name="month" select="//timestamp/@month"/> ! <xsl:variable name="year" select="//timestamp/@year"/> ! <xsl:value-of select="$day"/>/<xsl:value-of select="$month"/>/<xsl:value-of select="$year"/> <br /> ! <xsl:variable name="totalCount" select="count(integration)"/> ! <xsl:variable name="successCount" select="count(integration[@status='Success'])"/> ! <xsl:variable name="failureCount" select="$totalCount - $successCount"/> ! <xsl:variable name="totalCountForTheDay" select="count(integration[@day=$day and @month=$month and @year=$year])"/> ! <xsl:variable name="successCountForTheDay" select="count(integration[@status='Success' and @day=$day and @month=$month and @year=$year])"/> ! <xsl:variable name="failureCountForTheDay" select="$totalCountForTheDay - $successCountForTheDay"/> ! <table border="1" cellpadding="0" cellspacing="0"> ! <tr> ! <th>Integration Summary</th> ! <th>For today</th> ! <th>Overall</th> ! </tr> ! <tr> ! <th>Total Builds</th> ! <td><xsl:value-of select="$totalCountForTheDay"/></td> ! <td><xsl:value-of select="$totalCount"/></td> ! </tr> ! <tr> ! <th>Number of Successful</th> ! <td><xsl:value-of select="$successCountForTheDay"/></td> ! <td><xsl:value-of select="$successCount"/></td> ! </tr> ! <tr> ! <th>Number of Failed</th> ! <td><xsl:value-of select="$failureCountForTheDay"/></td> ! <td><xsl:value-of select="$failureCount"/></td> ! </tr> ! </table> ! </p> <table> <tr> *************** *** 26,29 **** --- 60,64 ---- </tr> <xsl:for-each select="./integration"> + <xsl:sort select="position()" data-type="number" order="descending"/> <xsl:variable name="colorClass"> <xsl:choose> |
|
From: Ashish <ash...@us...> - 2006-04-28 09:01:40
|
Update of /cvsroot/ccnet/ccnet/project/UnitTests/Core/Config In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv22317/project/UnitTests/Core/Config Modified Files: NetReflectorConfigurationReaderTest.cs Log Message: CCNET-642: Added XmlDocument Statistics { get; } to IProject. Sending the current date as part of the statistics document from server. This information is used for generating a daily and overall build summary for now. Index: NetReflectorConfigurationReaderTest.cs =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/UnitTests/Core/Config/NetReflectorConfigurationReaderTest.cs,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** NetReflectorConfigurationReaderTest.cs 27 Apr 2006 15:14:58 -0000 1.8 --- NetReflectorConfigurationReaderTest.cs 28 Apr 2006 09:01:36 -0000 1.9 *************** *** 109,112 **** --- 109,118 ---- public IIntegrationResult Integrate(IntegrationRequest request) { return null; } public void Purge(bool purgeWorkingDirectory, bool purgeArtifactDirectory, bool purgeSourceControlEnvironment) { } + + public XmlDocument Statistics + { + get { throw new NotImplementedException(); } + } + public void Initialize() {} |
|
From: Ashish <ash...@us...> - 2006-04-28 09:01:39
|
Update of /cvsroot/ccnet/ccnet/project/UnitTests/Core In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv22317/project/UnitTests/Core Modified Files: CruiseServerTest.cs Log Message: CCNET-642: Added XmlDocument Statistics { get; } to IProject. Sending the current date as part of the statistics document from server. This information is used for generating a daily and overall build summary for now. Index: CruiseServerTest.cs =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/UnitTests/Core/CruiseServerTest.cs,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** CruiseServerTest.cs 7 Apr 2006 05:59:08 -0000 1.6 --- CruiseServerTest.cs 28 Apr 2006 09:01:36 -0000 1.7 *************** *** 1,4 **** --- 1,5 ---- using System; using System.Threading; + using System.Xml; using NMock; using NUnit.Framework; *************** *** 17,20 **** --- 18,22 ---- private DynamicMock integratorMock1; private DynamicMock integratorMock2; + private DynamicMock integratorMock3; private CruiseServer server; *************** *** 23,31 **** --- 25,40 ---- private Project project1; private Project project2; + + private IMock mockProject; + private IProject mockProjectInstance; + private IProjectIntegrator integrator1; private IProjectIntegrator integrator2; + private IProjectIntegrator integrator3; private ProjectIntegratorList integratorList; private ManualResetEvent monitor; + private XmlDocument statistics; + private XmlDocument statisticsClone; [SetUp] *************** *** 36,55 **** --- 45,82 ---- integratorMock1 = new DynamicMock(typeof (IProjectIntegrator)); integratorMock2 = new DynamicMock(typeof (IProjectIntegrator)); + integratorMock3 = new DynamicMock(typeof (IProjectIntegrator)); integrator1 = (IProjectIntegrator) integratorMock1.MockInstance; integrator2 = (IProjectIntegrator) integratorMock2.MockInstance; + integrator3 = (IProjectIntegrator) integratorMock3.MockInstance; integratorMock1.SetupResult("Name", "Project 1"); integratorMock2.SetupResult("Name", "Project 2"); + integratorMock3.SetupResult("Name", "Project 3"); configuration = new Configuration(); project1 = new Project(); project1.Name = "Project 1"; + project2 = new Project(); project2.Name = "Project 2"; + + mockProject = new DynamicMock(typeof(IProject)); + statistics = new XmlDocument(); + XmlElement root = statistics.CreateElement("statistics"); + statistics.AppendChild(root); + statisticsClone = new XmlDocument(); + statisticsClone.LoadXml(statistics.OuterXml); + mockProject.ExpectAndReturn("Name", "Project 3"); + mockProject.ExpectAndReturn("Statistics", statistics); + mockProjectInstance = (IProject) mockProject.MockInstance; + integratorMock3.ExpectAndReturn("Project", mockProjectInstance); + configuration.AddProject(project1); configuration.AddProject(project2); + configuration.AddProject(mockProjectInstance); integratorList = new ProjectIntegratorList(); integratorList.Add(integrator1); integratorList.Add(integrator2); + integratorList.Add(integrator3); configServiceMock = new DynamicMock(typeof (IConfigurationService)); *************** *** 290,293 **** --- 317,340 ---- integratorMock2.Verify(); } + + [Test] + public void GetStatisticsDocumentSetsCurrentDate() + { + mockProject.ExpectAndReturn("Name", "Project 3"); + string statisticsDocument = server.GetStatisticsDocument(mockProjectInstance.Name); + XmlDocument fromServer = new XmlDocument(); + fromServer.LoadXml(statisticsDocument); + Assert.AreEqual(statisticsClone.DocumentElement.ChildNodes.Count + 1, fromServer.DocumentElement.ChildNodes.Count); + // XPathNavigator navigator = fromServer.CreateNavigator(); + // object o = navigator.Evaluate("/statistics//timestamp/@day"); + // string s = o.ToString(); + // int day = (int) o; + // int month = (int) navigator.Evaluate("/statistics//timestamp/@month"); + // int year = (int) navigator.Evaluate("/statistics//timestamp/@year"); + // + // Assert.AreEqual(DateTime.Now.Day, day); + // Assert.AreEqual(DateTime.Now.Month, month); + // Assert.AreEqual(DateTime.Now.Year, year); + } } } \ No newline at end of file |
|
From: Owen R. <exo...@us...> - 2006-04-27 15:15:13
|
Update of /cvsroot/ccnet/ccnet/project/core In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv15446/project/core Modified Files: CruiseManager.cs CruiseServer.cs IProject.cs Project.cs RemoteCruiseServer.cs Workflow.cs Log Message: CCNET-682 : fix build message now popups up in cctray Index: RemoteCruiseServer.cs =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/core/RemoteCruiseServer.cs,v retrieving revision 1.23 retrieving revision 1.24 diff -C2 -d -r1.23 -r1.24 *** RemoteCruiseServer.cs 27 Apr 2006 06:20:49 -0000 1.23 --- RemoteCruiseServer.cs 27 Apr 2006 15:14:58 -0000 1.24 *************** *** 49,53 **** public void Stop(string project) { ! throw new NotImplementedException(); } --- 49,53 ---- public void Stop(string project) { ! _server.Stop(project); } *************** *** 132,135 **** --- 132,140 ---- } + public void SendMessage(string projectName, Message message) + { + _server.SendMessage(projectName, message); + } + public string GetArtifactDirectory(string projectName) { Index: Workflow.cs =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/core/Workflow.cs,v retrieving revision 1.15 retrieving revision 1.16 diff -C2 -d -r1.15 -r1.16 *** Workflow.cs 20 Apr 2006 05:31:17 -0000 1.15 --- Workflow.cs 27 Apr 2006 15:14:58 -0000 1.16 *************** *** 81,84 **** --- 81,89 ---- } + public void AddMessage(Message message) + { + throw new NotImplementedException(); + } + public int MinimumSleepTimeMillis { Index: CruiseManager.cs =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/core/CruiseManager.cs,v retrieving revision 1.39 retrieving revision 1.40 diff -C2 -d -r1.39 -r1.40 *** CruiseManager.cs 27 Apr 2006 06:20:49 -0000 1.39 --- CruiseManager.cs 27 Apr 2006 15:14:58 -0000 1.40 *************** *** 43,49 **** } ! public void FixBuild(string projectName) { ! throw new NotImplementedException(); } --- 43,49 ---- } ! public void SendMessage(string projectName, Message message) { ! cruiseServer.SendMessage(projectName, message); } Index: CruiseServer.cs =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/core/CruiseServer.cs,v retrieving revision 1.44 retrieving revision 1.45 diff -C2 -d -r1.44 -r1.45 *** CruiseServer.cs 27 Apr 2006 06:20:49 -0000 1.44 --- CruiseServer.cs 27 Apr 2006 15:14:58 -0000 1.45 *************** *** 305,309 **** { Log.Info("Getting project - " + name); ! return new NetReflectorProjectSerializer().Serialize((Project) configurationService.Load().Projects[name]); } --- 305,309 ---- { Log.Info("Getting project - " + name); ! return new NetReflectorProjectSerializer().Serialize(configurationService.Load().Projects[name]); } *************** *** 349,352 **** --- 349,358 ---- } + public void SendMessage(string projectName, Message message) + { + Log.Info("New message received: " + message); + GetIntegrator(projectName).Project.AddMessage(message); + } + public string GetArtifactDirectory(string projectName) { Index: IProject.cs =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/core/IProject.cs,v retrieving revision 1.24 retrieving revision 1.25 diff -C2 -d -r1.24 -r1.25 *** IProject.cs 21 Apr 2006 04:29:04 -0000 1.24 --- IProject.cs 27 Apr 2006 15:14:58 -0000 1.25 *************** *** 58,61 **** --- 58,62 ---- void Initialize(); ProjectStatus CreateProjectStatus(IProjectIntegrator integrator); + void AddMessage(Message message); } } Index: Project.cs =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/core/Project.cs,v retrieving revision 1.68 retrieving revision 1.69 diff -C2 -d -r1.68 -r1.69 *** Project.cs 21 Apr 2006 04:29:04 -0000 1.68 --- Project.cs 27 Apr 2006 15:14:58 -0000 1.69 *************** *** 46,49 **** --- 46,50 ---- private IIntegratable integratable; private QuietPeriod quietPeriod = new QuietPeriod(new DateTimeProvider()); + private ArrayList messages = new ArrayList(); public Project() *************** *** 214,220 **** public ProjectStatus CreateProjectStatus(IProjectIntegrator integrator) { ! return new ProjectStatus(Name, CurrentActivity, LatestBuildStatus, integrator.State, WebURL, ! LastIntegrationResult.StartTime, LastIntegrationResult.Label, LastIntegrationResult.LastSuccessfulIntegrationLabel, ! Triggers.NextBuild); } } --- 215,228 ---- public ProjectStatus CreateProjectStatus(IProjectIntegrator integrator) { ! ProjectStatus status = new ProjectStatus(Name, CurrentActivity, LatestBuildStatus, integrator.State, WebURL, ! LastIntegrationResult.StartTime, LastIntegrationResult.Label, LastIntegrationResult.LastSuccessfulIntegrationLabel, ! Triggers.NextBuild); ! status.Messages = (Message[])messages.ToArray(typeof(Message)); ! return status; ! } ! ! public void AddMessage(Message message) ! { ! messages.Add(message); } } |
|
From: Owen R. <exo...@us...> - 2006-04-27 15:15:06
|
Update of /cvsroot/ccnet/ccnet/project/CCTrayLib/Monitoring In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv15446/project/CCTrayLib/Monitoring Modified Files: AggregatingProjectMonitor.cs CruiseProjectManager.cs DashboardCruiseProjectManager.cs IPollable.cs IProjectMonitor.cs MonitorBuildOccurredEventArgs.cs ProjectMonitor.cs Log Message: CCNET-682 : fix build message now popups up in cctray Index: AggregatingProjectMonitor.cs =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/CCTrayLib/Monitoring/AggregatingProjectMonitor.cs,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** AggregatingProjectMonitor.cs 19 Apr 2006 15:33:10 -0000 1.10 --- AggregatingProjectMonitor.cs 27 Apr 2006 15:14:57 -0000 1.11 *************** *** 17,20 **** --- 17,21 ---- monitor.Polled += new MonitorPolledEventHandler(Monitor_Polled); monitor.BuildOccurred += new MonitorBuildOccurredEventHandler(Monitor_BuildOccurred); + monitor.MessageReceived += new MessageEventHandler(Monitor_MessageReceived); } } *************** *** 59,79 **** public event MonitorBuildOccurredEventHandler BuildOccurred; private void Monitor_BuildOccurred(object sender, MonitorBuildOccurredEventArgs e) { ! if (BuildOccurred != null) ! { ! BuildOccurred(this, e); ! } } - public event MonitorPolledEventHandler Polled; - private void Monitor_Polled(object sender, MonitorPolledEventArgs args) { ! if (Polled != null) ! { ! Polled(this, args); ! } } --- 60,79 ---- public event MonitorBuildOccurredEventHandler BuildOccurred; + public event MonitorPolledEventHandler Polled; + public event MessageEventHandler MessageReceived; private void Monitor_BuildOccurred(object sender, MonitorBuildOccurredEventArgs e) { ! if (BuildOccurred != null) BuildOccurred(this, e); } private void Monitor_Polled(object sender, MonitorPolledEventArgs args) { ! if (Polled != null) Polled(this, args); ! } ! ! private void Monitor_MessageReceived(Message message) ! { ! if (MessageReceived != null) MessageReceived(message); } *************** *** 149,153 **** get { throw new InvalidOperationException(); } } - } } \ No newline at end of file --- 149,152 ---- Index: DashboardCruiseProjectManager.cs =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/CCTrayLib/Monitoring/DashboardCruiseProjectManager.cs,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** DashboardCruiseProjectManager.cs 19 Apr 2006 15:33:10 -0000 1.3 --- DashboardCruiseProjectManager.cs 27 Apr 2006 15:14:57 -0000 1.4 *************** *** 26,30 **** public void FixBuild() { ! throw new NotImplementedException(); } --- 26,30 ---- public void FixBuild() { ! throw new NotImplementedException("Fix build not currently supported on dashboard projects"); } Index: ProjectMonitor.cs =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/CCTrayLib/Monitoring/ProjectMonitor.cs,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -d -r1.13 -r1.14 *** ProjectMonitor.cs 19 Apr 2006 15:33:10 -0000 1.13 --- ProjectMonitor.cs 27 Apr 2006 15:14:57 -0000 1.14 *************** *** 4,8 **** namespace ThoughtWorks.CruiseControl.CCTrayLib.Monitoring ! { public class ProjectMonitor : IProjectMonitor, ISingleProjectDetail { --- 4,8 ---- namespace ThoughtWorks.CruiseControl.CCTrayLib.Monitoring ! { public class ProjectMonitor : IProjectMonitor, ISingleProjectDetail { *************** *** 116,127 **** { CheckForBuildStart(lastProjectStatus, newProjectStatus); ! if (lastProjectStatus.LastBuildDate != newProjectStatus.LastBuildDate) { BuildTransition transition = CalculateBuildTransition(lastProjectStatus, newProjectStatus); ! CheckForSuccessfulBuild(transition); OnBuildOccurred(new MonitorBuildOccurredEventArgs(this, transition)); } } lastProjectStatus = newProjectStatus; --- 116,132 ---- { CheckForBuildStart(lastProjectStatus, newProjectStatus); ! if (lastProjectStatus.LastBuildDate != newProjectStatus.LastBuildDate) { BuildTransition transition = CalculateBuildTransition(lastProjectStatus, newProjectStatus); ! CheckForSuccessfulBuild(transition); OnBuildOccurred(new MonitorBuildOccurredEventArgs(this, transition)); } + + if (lastProjectStatus.Messages.Length < newProjectStatus.Messages.Length) + { + OnMessageReceived(newProjectStatus.Messages[newProjectStatus.Messages.Length - 1]); + } } lastProjectStatus = newProjectStatus; *************** *** 156,170 **** public event MonitorBuildOccurredEventHandler BuildOccurred; public event MonitorPolledEventHandler Polled; protected void OnBuildOccurred(MonitorBuildOccurredEventArgs args) { ! if (BuildOccurred != null) ! BuildOccurred(this, args); } protected void OnPolled(MonitorPolledEventArgs args) { ! if (Polled != null) ! Polled(this, args); } --- 161,179 ---- public event MonitorBuildOccurredEventHandler BuildOccurred; public event MonitorPolledEventHandler Polled; + public event MessageEventHandler MessageReceived; protected void OnBuildOccurred(MonitorBuildOccurredEventArgs args) { ! if (BuildOccurred != null) BuildOccurred(this, args); } protected void OnPolled(MonitorPolledEventArgs args) { ! if (Polled != null) Polled(this, args); ! } ! ! private void OnMessageReceived(Message message) ! { ! if (MessageReceived != null) MessageReceived(message); } *************** *** 199,203 **** } - public TimeSpan EstimatedTimeRemainingOnCurrentBuild { --- 208,211 ---- *************** *** 205,207 **** --- 213,217 ---- } } + + public delegate void MessageEventHandler(Message message); } \ No newline at end of file Index: CruiseProjectManager.cs =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/CCTrayLib/Monitoring/CruiseProjectManager.cs,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** CruiseProjectManager.cs 19 Apr 2006 15:33:10 -0000 1.4 --- CruiseProjectManager.cs 27 Apr 2006 15:14:57 -0000 1.5 *************** *** 25,29 **** public void FixBuild() { ! manager.FixBuild(ProjectName); } --- 25,29 ---- public void FixBuild() { ! manager.SendMessage(ProjectName, new Message(string.Format("{0} is fixing the build.", Environment.UserName))); } Index: IPollable.cs =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/CCTrayLib/Monitoring/IPollable.cs,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** IPollable.cs 19 Sep 2005 10:42:07 -0000 1.2 --- IPollable.cs 27 Apr 2006 15:14:57 -0000 1.3 *************** *** 5,8 **** void Poll(); } - } \ No newline at end of file --- 5,7 ---- Index: IProjectMonitor.cs =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/CCTrayLib/Monitoring/IProjectMonitor.cs,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** IProjectMonitor.cs 19 Apr 2006 15:33:10 -0000 1.8 --- IProjectMonitor.cs 27 Apr 2006 15:14:57 -0000 1.9 *************** *** 18,21 **** --- 18,22 ---- event MonitorBuildOccurredEventHandler BuildOccurred; event MonitorPolledEventHandler Polled; + event MessageEventHandler MessageReceived; void ForceBuild(); Index: MonitorBuildOccurredEventArgs.cs =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/CCTrayLib/Monitoring/MonitorBuildOccurredEventArgs.cs,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** MonitorBuildOccurredEventArgs.cs 30 May 2005 12:22:13 -0000 1.1 --- MonitorBuildOccurredEventArgs.cs 27 Apr 2006 15:14:57 -0000 1.2 *************** *** 8,12 **** public readonly BuildTransition BuildTransition; ! public MonitorBuildOccurredEventArgs( IProjectMonitor projectMonitor, BuildTransition buildTransition ) { ProjectMonitor = projectMonitor; --- 8,12 ---- public readonly BuildTransition BuildTransition; ! public MonitorBuildOccurredEventArgs(IProjectMonitor projectMonitor, BuildTransition buildTransition) { ProjectMonitor = projectMonitor; *************** *** 15,19 **** } ! public delegate void MonitorBuildOccurredEventHandler( object sender, MonitorBuildOccurredEventArgs e ); ! } \ No newline at end of file --- 15,18 ---- } ! public delegate void MonitorBuildOccurredEventHandler(object sender, MonitorBuildOccurredEventArgs e); } \ No newline at end of file |
|
From: Owen R. <exo...@us...> - 2006-04-27 15:15:06
|
Update of /cvsroot/ccnet/ccnet/project/UnitTests/Core In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv15446/project/UnitTests/Core Modified Files: ProjectTest.cs Log Message: CCNET-682 : fix build message now popups up in cctray Index: ProjectTest.cs =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/UnitTests/Core/ProjectTest.cs,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -d -r1.13 -r1.14 *** ProjectTest.cs 21 Apr 2006 04:29:04 -0000 1.13 --- ProjectTest.cs 27 Apr 2006 15:14:58 -0000 1.14 *************** *** 26,30 **** private IMock mockSourceControl; private IMock mockStateManager; ! private IMock mockIntegrationTrigger; private IMock mockLabeller; private IMock mockPublisher; --- 26,30 ---- private IMock mockSourceControl; private IMock mockStateManager; ! private IMock mockTrigger; private IMock mockLabeller; private IMock mockPublisher; *************** *** 48,53 **** mockStateManager = new DynamicMock(typeof (IStateManager)); mockStateManager.Strict = true; ! mockIntegrationTrigger = new DynamicMock(typeof (ITrigger)); ! mockIntegrationTrigger.Strict = true; mockLabeller = new DynamicMock(typeof (ILabeller)); mockLabeller.Strict = true; --- 48,53 ---- mockStateManager = new DynamicMock(typeof (IStateManager)); mockStateManager.Strict = true; ! mockTrigger = new DynamicMock(typeof (ITrigger)); ! mockTrigger.Strict = true; mockLabeller = new DynamicMock(typeof (ILabeller)); mockLabeller.Strict = true; *************** *** 67,71 **** project.SourceControl = (ISourceControl) mockSourceControl.MockInstance; project.StateManager = (IStateManager) mockStateManager.MockInstance; ! project.Triggers = (ITrigger) mockIntegrationTrigger.MockInstance; project.Labeller = (ILabeller) mockLabeller.MockInstance; project.Publishers = new ITask[] {(ITask) mockPublisher.MockInstance}; --- 67,71 ---- project.SourceControl = (ISourceControl) mockSourceControl.MockInstance; project.StateManager = (IStateManager) mockStateManager.MockInstance; ! project.Triggers = (ITrigger) mockTrigger.MockInstance; project.Labeller = (ILabeller) mockLabeller.MockInstance; project.Publishers = new ITask[] {(ITask) mockPublisher.MockInstance}; *************** *** 80,84 **** mockSourceControl.Verify(); mockStateManager.Verify(); ! mockIntegrationTrigger.Verify(); mockLabeller.Verify(); mockPublisher.Verify(); --- 80,84 ---- mockSourceControl.Verify(); mockStateManager.Verify(); ! mockTrigger.Verify(); mockLabeller.Verify(); mockPublisher.Verify(); *************** *** 610,613 **** --- 610,625 ---- VerifyAll(); } + + [Test] + public void AddedMessageShouldBeIncludedInProjectStatus() + { + mockStateManager.ExpectAndReturn("LoadState", IntegrationResult.CreateInitialIntegrationResult(ProjectName, @"c:\temp"), ProjectName); + mockTrigger.ExpectAndReturn("NextBuild", DateTime.Now); + + Message message = new Message("foo"); + project.AddMessage(message); + ProjectStatus status = project.CreateProjectStatus(new ProjectIntegrator(project)); + Assert.AreEqual(message, status.Messages[0]); + } } } \ No newline at end of file |
|
From: Owen R. <exo...@us...> - 2006-04-27 15:15:06
|
Update of /cvsroot/ccnet/ccnet/project/UnitTests/Core/Util In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv15446/project/UnitTests/Core/Util Modified Files: XmlFragmentWriterTest.cs Log Message: CCNET-682 : fix build message now popups up in cctray Index: XmlFragmentWriterTest.cs =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/UnitTests/Core/Util/XmlFragmentWriterTest.cs,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** XmlFragmentWriterTest.cs 28 Sep 2005 13:50:33 -0000 1.7 --- XmlFragmentWriterTest.cs 27 Apr 2006 15:14:58 -0000 1.8 *************** *** 128,132 **** { StringBuilder builder = new StringBuilder(); ! for (int i = 0; i < 31; i++) { builder.Append((char) i, 1); --- 128,132 ---- { StringBuilder builder = new StringBuilder(); ! for (int i = 0; i < 31; i++) { builder.Append((char) i, 1); |
|
From: Owen R. <exo...@us...> - 2006-04-27 15:15:06
|
Update of /cvsroot/ccnet/ccnet/project/UnitTests/CCTrayLib/Monitoring In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv15446/project/UnitTests/CCTrayLib/Monitoring Modified Files: ProjectMonitorTest.cs Log Message: CCNET-682 : fix build message now popups up in cctray Index: ProjectMonitorTest.cs =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/UnitTests/CCTrayLib/Monitoring/ProjectMonitorTest.cs,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -d -r1.13 -r1.14 *** ProjectMonitorTest.cs 19 Apr 2006 15:33:10 -0000 1.13 --- ProjectMonitorTest.cs 27 Apr 2006 15:14:58 -0000 1.14 *************** *** 17,20 **** --- 17,21 ---- private int buildOccurredCount; private MonitorBuildOccurredEventArgs lastBuildOccurredArgs; + private Message actualMessage; [SetUp] *************** *** 33,36 **** --- 34,38 ---- { mockProjectManager.Verify(); + actualMessage = null; } *************** *** 285,288 **** --- 287,312 ---- mockProjectManager.Verify(); } + + [Test] + public void DisplayBalloonMessageWhenNewMessageIsReceived() + { + ProjectStatus initial = ProjectStatusFixture.New(IntegrationStatus.Success, ProjectActivity.Sleeping); + mockProjectManager.ExpectAndReturn("ProjectStatus", initial); + + Message expectedMessage = new Message("foo"); + ProjectStatus newStatus = ProjectStatusFixture.New(IntegrationStatus.Success, ProjectActivity.Sleeping); + newStatus.Messages = new Message[] { expectedMessage}; + mockProjectManager.ExpectAndReturn("ProjectStatus", newStatus); + + monitor.MessageReceived += new MessageEventHandler(OnMessageReceived); + monitor.Poll(); + monitor.Poll(); + Assert.AreEqual(actualMessage, expectedMessage); + } + + private void OnMessageReceived(Message message) + { + actualMessage = message; + } } } \ No newline at end of file |
|
From: Owen R. <exo...@us...> - 2006-04-27 15:15:06
|
Update of /cvsroot/ccnet/ccnet/project/UnitTests/Core/Config In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv15446/project/UnitTests/Core/Config Modified Files: NetReflectorConfigurationReaderTest.cs Log Message: CCNET-682 : fix build message now popups up in cctray Index: NetReflectorConfigurationReaderTest.cs =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/UnitTests/Core/Config/NetReflectorConfigurationReaderTest.cs,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** NetReflectorConfigurationReaderTest.cs 20 Apr 2006 05:31:17 -0000 1.7 --- NetReflectorConfigurationReaderTest.cs 27 Apr 2006 15:14:58 -0000 1.8 *************** *** 116,119 **** --- 116,124 ---- } + public void AddMessage(Message message) + { + throw new NotImplementedException(); + } + public string WebURL { get {return ""; } } } |
|
From: Owen R. <exo...@us...> - 2006-04-27 15:15:06
|
Update of /cvsroot/ccnet/ccnet/project/UnitTests/CCTrayLib/Presentation In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv15446/project/UnitTests/CCTrayLib/Presentation Modified Files: StubProjectMonitor.cs Log Message: CCNET-682 : fix build message now popups up in cctray Index: StubProjectMonitor.cs =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/UnitTests/CCTrayLib/Presentation/StubProjectMonitor.cs,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** StubProjectMonitor.cs 19 Apr 2006 15:33:10 -0000 1.6 --- StubProjectMonitor.cs 27 Apr 2006 15:14:58 -0000 1.7 *************** *** 96,99 **** --- 96,100 ---- public event MonitorBuildOccurredEventHandler BuildOccurred; public event MonitorPolledEventHandler Polled; + public event MessageEventHandler MessageReceived; public void Poll() |
|
From: Owen R. <exo...@us...> - 2006-04-27 15:15:06
|
Update of /cvsroot/ccnet/ccnet/project/Remote In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv15446/project/Remote Modified Files: ICruiseManager.cs ICruiseServer.cs ProjectStatus.cs Remote.csproj Added Files: Message.cs Log Message: CCNET-682 : fix build message now popups up in cctray --- NEW FILE: Message.cs --- using System; namespace ThoughtWorks.CruiseControl.Remote { [Serializable] public class Message { private string message; public Message(string message) { this.message = message; } public override string ToString() { return message; } } } Index: Remote.csproj =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/Remote/Remote.csproj,v retrieving revision 1.21 retrieving revision 1.22 diff -C2 -d -r1.21 -r1.22 *** Remote.csproj 7 Apr 2006 05:59:08 -0000 1.21 --- Remote.csproj 27 Apr 2006 15:14:58 -0000 1.22 *************** *** 176,179 **** --- 176,184 ---- /> <File + RelPath = "Message.cs" + SubType = "Code" + BuildAction = "Compile" + /> + <File RelPath = "NoSuchProjectException.cs" SubType = "Code" Index: ProjectStatus.cs =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/Remote/ProjectStatus.cs,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** ProjectStatus.cs 25 Mar 2006 00:32:17 -0000 1.10 --- ProjectStatus.cs 27 Apr 2006 15:14:58 -0000 1.11 *************** *** 91,94 **** --- 91,96 ---- get { return nextBuildTime.DateTime; } } + + public Message[] Messages = new Message[0]; } } \ No newline at end of file Index: ICruiseManager.cs =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/Remote/ICruiseManager.cs,v retrieving revision 1.17 retrieving revision 1.18 diff -C2 -d -r1.17 -r1.18 *** ICruiseManager.cs 27 Apr 2006 06:20:49 -0000 1.17 --- ICruiseManager.cs 27 Apr 2006 15:14:58 -0000 1.18 *************** *** 1,3 **** - namespace ThoughtWorks.CruiseControl.Remote { --- 1,2 ---- *************** *** 21,25 **** void Start(string project); void Stop(string project); ! void FixBuild(string projectName); void WaitForExit(string projectName); --- 20,24 ---- void Start(string project); void Stop(string project); ! void SendMessage(string projectName, Message message); void WaitForExit(string projectName); Index: ICruiseServer.cs =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/Remote/ICruiseServer.cs,v retrieving revision 1.15 retrieving revision 1.16 diff -C2 -d -r1.15 -r1.16 *** ICruiseServer.cs 27 Apr 2006 06:20:49 -0000 1.15 --- ICruiseServer.cs 27 Apr 2006 15:14:58 -0000 1.16 *************** *** 99,102 **** --- 99,103 ---- ExternalLink[] GetExternalLinks(string projectName); + void SendMessage(string projectName, Message message); string GetArtifactDirectory(string projectName); |
|
From: Owen R. <exo...@us...> - 2006-04-27 15:15:03
|
Update of /cvsroot/ccnet/ccnet/project/CCTrayLib/Presentation In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv15446/project/CCTrayLib/Presentation Modified Files: SynchronizedProjectMonitor.cs TrayIcon.cs Log Message: CCNET-682 : fix build message now popups up in cctray Index: TrayIcon.cs =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/CCTrayLib/Presentation/TrayIcon.cs,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** TrayIcon.cs 15 Sep 2005 14:54:22 -0000 1.8 --- TrayIcon.cs 27 Apr 2006 15:14:57 -0000 1.9 *************** *** 3,6 **** --- 3,7 ---- using ThoughtWorks.CruiseControl.CCTrayLib.Configuration; using ThoughtWorks.CruiseControl.CCTrayLib.Monitoring; + using ThoughtWorks.CruiseControl.Remote; namespace ThoughtWorks.CruiseControl.CCTrayLib.Presentation *************** *** 36,43 **** if (showBalloonMessages) monitor.BuildOccurred += new MonitorBuildOccurredEventHandler(Monitor_BuildOccurred); } ! private void IconProvider_IconChanged(object sender, EventArgs e) { --- 37,52 ---- if (showBalloonMessages) + { monitor.BuildOccurred += new MonitorBuildOccurredEventHandler(Monitor_BuildOccurred); + monitor.MessageReceived += new MessageEventHandler(Monitor_MessageReceived); + } } ! private void Monitor_MessageReceived(Message message) ! { ! ShowBalloon(message.ToString(), message.ToString(), NotifyInfoFlags.Info, 5000); ! } ! ! private void IconProvider_IconChanged(object sender, EventArgs e) { Index: SynchronizedProjectMonitor.cs =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/CCTrayLib/Presentation/SynchronizedProjectMonitor.cs,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** SynchronizedProjectMonitor.cs 19 Apr 2006 15:33:10 -0000 1.7 --- SynchronizedProjectMonitor.cs 27 Apr 2006 15:14:57 -0000 1.8 *************** *** 22,25 **** --- 22,26 ---- projectMonitor.Polled += new MonitorPolledEventHandler(ProjectMonitor_Polled); projectMonitor.BuildOccurred += new MonitorBuildOccurredEventHandler(ProjectMonitor_BuildOccurred); + projectMonitor.MessageReceived += new MessageEventHandler(ProjectMonitor_MessageReceived); } *************** *** 58,78 **** public event MonitorBuildOccurredEventHandler BuildOccurred; public event MonitorPolledEventHandler Polled; private void ProjectMonitor_Polled(object sender, MonitorPolledEventArgs args) { ! if (Polled != null) ! { ! synchronizeInvoke.BeginInvoke(Polled, new object[] {sender, args}); ! } } private void ProjectMonitor_BuildOccurred(object sender, MonitorBuildOccurredEventArgs args) { ! if (BuildOccurred != null) ! { ! synchronizeInvoke.BeginInvoke(BuildOccurred, new object[] {sender, args}); ! } } public IntegrationStatus IntegrationStatus --- 59,78 ---- public event MonitorBuildOccurredEventHandler BuildOccurred; public event MonitorPolledEventHandler Polled; + public event MessageEventHandler MessageReceived; private void ProjectMonitor_Polled(object sender, MonitorPolledEventArgs args) { ! if (Polled != null) synchronizeInvoke.BeginInvoke(Polled, new object[] {sender, args}); } private void ProjectMonitor_BuildOccurred(object sender, MonitorBuildOccurredEventArgs args) { ! if (BuildOccurred != null) synchronizeInvoke.BeginInvoke(BuildOccurred, new object[] {sender, args}); } + private void ProjectMonitor_MessageReceived(Message message) + { + if (MessageReceived != null) synchronizeInvoke.BeginInvoke(MessageReceived, new object[] {message}); + } public IntegrationStatus IntegrationStatus |
|
From: Ashish <ash...@us...> - 2006-04-27 08:12:53
|
Update of /cvsroot/ccnet/ccnet/project/xsl In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv30112/project/xsl Modified Files: statistics.xsl Log Message: CCNET-642: Formatting report Index: statistics.xsl =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/xsl/statistics.xsl,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** statistics.xsl 27 Apr 2006 07:46:21 -0000 1.2 --- statistics.xsl 27 Apr 2006 08:12:44 -0000 1.3 *************** *** 18,21 **** --- 18,22 ---- <tr> <th>Build Label</th> + <th>Status</th> <xsl:for-each select="./integration[1]/statistic"> <th> *************** *** 27,39 **** <xsl:variable name="colorClass"> <xsl:choose> ! <xsl:when test="./@status = 0">pass</xsl:when> ! <xsl:when test="./@status = 3" >unknown</xsl:when> <xsl:otherwise>fail</xsl:otherwise> </xsl:choose> </xsl:variable> ! <tr class="{$colorClass}"> <th> <xsl:value-of select="./@build-label"/> </th> <xsl:for-each select="./statistic"> <td> --- 28,43 ---- <xsl:variable name="colorClass"> <xsl:choose> ! <xsl:when test="./@status = 'Success'">pass</xsl:when> ! <xsl:when test="./@status = 'Unknown'" >unknown</xsl:when> <xsl:otherwise>fail</xsl:otherwise> </xsl:choose> </xsl:variable> ! <tr> <th> <xsl:value-of select="./@build-label"/> </th> + <th class="{$colorClass}"> + <xsl:value-of select="./@status"/> + </th> <xsl:for-each select="./statistic"> <td> |
|
From: Ashish <ash...@us...> - 2006-04-27 08:12:53
|
Update of /cvsroot/ccnet/ccnet/project/core/publishers/Statistics In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv30112/project/core/publishers/Statistics Modified Files: StatisticsPublisher.cs Log Message: CCNET-642: Formatting report Index: StatisticsPublisher.cs =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/core/publishers/Statistics/StatisticsPublisher.cs,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** StatisticsPublisher.cs 27 Apr 2006 07:46:22 -0000 1.4 --- StatisticsPublisher.cs 27 Apr 2006 08:12:44 -0000 1.5 *************** *** 52,56 **** xml.SetAttribute("build-label", integrationResult.Label); IntegrationStatus status = integrationResult.Status; ! xml.SetAttribute("status", ((int) status).ToString()); root.AppendChild(xml); --- 52,56 ---- xml.SetAttribute("build-label", integrationResult.Label); IntegrationStatus status = integrationResult.Status; ! xml.SetAttribute("status", status.ToString()); root.AppendChild(xml); |
|
From: Ashish <ash...@us...> - 2006-04-27 07:46:29
|
Update of /cvsroot/ccnet/ccnet/project/WebDashboard In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv7325/project/WebDashboard Modified Files: dashboard.config Log Message: CCNET-642: Adding css class to the Build Statistics, also added IntegrationStatus to the statistics Index: dashboard.config =================================================================== RCS file: /cvsroot/ccnet/ccnet/project/WebDashboard/dashboard.config,v retrieving revision 1.17 retrieving revision 1.18 diff -C2 -d -r1.17 -r1.18 *** dashboard.config 27 Apr 2006 06:20:50 -0000 1.17 --- dashboard.config 27 Apr 2006 07:46:21 -0000 1.18 *************** *** 21,25 **** <latestBuildReportProjectPlugin /> <viewAllBuildsProjectPlugin /> ! <!-- <projectStatisticsPlugin xslFileName="xsl\statistics.xsl" /> --> </projectPlugins> <buildPlugins> --- 21,25 ---- <latestBuildReportProjectPlugin /> <viewAllBuildsProjectPlugin /> ! <projectStatisticsPlugin xslFileName="xsl\statistics.xsl" /> </projectPlugins> <buildPlugins> |