Login | Register
My pages Projects Community openCollabNet

Discussions > commits > [chorns] 568: Smoketest target

sin
Discussion topic

Back to topic list

[chorns] 568: Smoketest target

Reply

Author chorns
Full name Casper Hornstrup
Date 2005-12-18 09:20:54 PST
Message Smoketest target
Modified: branches/0.1/Default.build
Added: branches/0.1/Sin.Con​figuration.Template/​Sin.Smoketest.exe.co​nfig
Modified: branches/0.1/Sin.Lib​rary/SubversionRepos​itory.cs
Modified: branches/0.1/Sin.Set​up/Build.txt
Added: branches/0.1/Sin.Smoketest/
Modified: branches/0.1/Sin.cmbx
  _____

Modified: branches/0.1/Default.build
--- branches/0.1/Default.build 2005-12-18 17:14:24 UTC (rev 567)
+++ branches/0.1/Default.build 2005-12-18 17:20:10 UTC (rev 568)
@@ -21,6 +21,7 @@

     <target name="init" description="Initialize properties">
         <property name="configuration.dir"
value="Sin.Configuration" />
         <property name="configuration.​template.dir"
value="Sin.Configura​tion.Template" />
+ <property name="repository.dir" value="Data/Repository"
/>
     </target>
 
     <target name="defaultconfig" description="Create default
configuration if it does not exist" depends="init">
@@ -56,6 +57,7 @@
         <nant buildfile="Sin.Tray/​Default.build" />
         <nant buildfile="Sin.Tests​/Default.build" />
         <nant buildfile="CodeCover​age.Tests/Default.bu​ild" />
+ <nant buildfile="Sin.Smoke​test/Default.build" />
     </target>
 
     <target name="dev" description="Prepare a Sin system in the
development environment" depends="init build">
@@ -66,6 +68,7 @@
                 <include
name="Sin.Integratio​nManager.Service.exe​.config" />
                 <include
name="Sin.Integrator​.Service.exe.config"​ />
                 <include
name="Sin.Integratio​nManager.PostCommit.​exe.config" />
+ <include name="Sin.Smoketest.exe.config"
/>
             </fileset>
         </copy>
         <copy
file="${configurati​on.dir}\Sin.Integra​tionManager.Controll​er.Web.config"
@@ -94,6 +97,12 @@
         <exec program="sc" commandline="stop &quot;Integrator
Service&quot;" />
     </target>
 
+ <target name="smoketest" description="Run smoketest on Sin
system running in the development environment" depends="stop">
+ <call target="start" />
+ <sleep seconds="4" />
+ <exec program="bin/Sin.Smoketest.exe" commandline=""
failonerror="false" />
+ </target>
+
     <target name="msi" description="Build Microsoft Installer
distribution" depends="init build">
         <nant buildfile="Sin.Setup​/Default.build" />
     </target>
  _____

Added: branches/0.1/Sin.Con​figuration.Template/​Sin.Smoketest.exe.co​nfig
--- branches/0.1/Sin.Con​figuration.Template/​Sin.Smoketest.exe.co​nfig
2005-12-18 12:49:43 UTC (rev 566)
+++ branches/0.1/Sin.Con​figuration.Template/​Sin.Smoketest.exe.co​nfig
2005-12-18 17:14:24 UTC (rev 567)
@@ -0,0 +1,9 @@

+<?xml version="1.0" encoding="utf-8" ?>
+<configuration>
+ <appSettings>
+ <add key="svnApplication" value="C:\Program
Files\Subversion\bin\svn.exe" />
+ <add key="subversionRepository"
value="file:///c:/Si​n/Repository" />
+ <add key="subversionUserName" value="user1" />
+ <add key="subversionPassword" value="" />
+ </appSettings>
+</configuration>
  _____

Modified: branches/0.1/Sin.Lib​rary/SubversionRepos​itory.cs
--- branches/0.1/Sin.Lib​rary/SubversionRepos​itory.cs 2005-12-18
17:14:24 UTC (rev 567)
+++ branches/0.1/Sin.Lib​rary/SubversionRepos​itory.cs 2005-12-18
17:20:10 UTC (rev 568)
@@ -1578,9 +1578,9 @@

         public void CopyBranch(string branch,
                                BranchType fromBranchType,
                                BranchType toBranchType,
- string commitmessage,
- Revision revision,
- out Revision newRevision)
+ string commitmessage,
+ Revision revision,
+ out Revision newRevision)
         {
             if (fromBranchType == toBranchType && revision
== Revision.Head)
                 throw new
InvalidOperationExce​ption("Cannot copy branch to itself.");
  _____

Modified: branches/0.1/Sin.Set​up/Build.txt
--- branches/0.1/Sin.Set​up/Build.txt 2005-12-18 17:14:24 UTC (rev
567)
+++ branches/0.1/Sin.Set​up/Build.txt 2005-12-18 17:20:10 UTC (rev
568)
@@ -36,6 +36,8 @@

 
     stop: Depends on dev target. Stop a Sin system running in the
development environment.
 
+ smoketest: Depends on dev target. Run smoke tests on Sin system
running in the development environment.
+
     zip: Depends on build target. Build ZIP distribution.
 
     msi: Depends on build target. Build Microsoft Installer
distribution.
  _____

Added: branches/0.1/Sin.Smo​ketest/AssemblyInfo.​cs
--- branches/0.1/Sin.Smo​ketest/AssemblyInfo.​cs 2005-12-18 12:49:43 UTC
(rev 566)
+++ branches/0.1/Sin.Smo​ketest/AssemblyInfo.​cs 2005-12-18 17:14:24 UTC
(rev 567)
@@ -0,0 +1,32 @@

+/*
+ * Copyright (C) 2005 Casper S. Hornstrup
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ */
+using System.Reflection;
+using System.Runtime.Compi​lerServices;
+
+[assembly: AssemblyTitle("Sin Smoketest")]
+[assembly: AssemblyDescription("Smoke testing of Sin")]
+[assembly: AssemblyConfiguration("")]
+[assembly: AssemblyCompany("CSH Consult")]
+[assembly: AssemblyProduct("Sin - Continuous Integration for
Subversion")]
+[assembly: AssemblyCopyright("Copyright 2005 Casper S. Hornstrup")]
+[assembly: AssemblyTrademark("")]
+[assembly: AssemblyCulture("")]
+[assembly: AssemblyVersion("0.1.*")]
+
+[assembly: AssemblyDelaySign(false)]
+[assembly: AssemblyKeyFile("")]
  _____

Added: branches/0.1/Sin.Smo​ketest/Default.build​
--- branches/0.1/Sin.Smo​ketest/Default.build​ 2005-12-18 12:49:43 UTC
(rev 566)
+++ branches/0.1/Sin.Smo​ketest/Default.build​ 2005-12-18 17:14:24 UTC
(rev 567)
@@ -0,0 +1,43 @@

+<?xml version="1.0"?>
+<!--
+ Copyright (C) 2005 Casper S. Hornstrup
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+-->
+<project name="Sin.Smoketest" default="build">
+
+ <property name="output.dir" value="..\bin" />
+
+ <target name="build" description="Build component">
+ <mkdir dir="${output.dir}" />
+ <csc target="exe"
+ output="${output.di​r}\Sin.Smoketest.ex​e"
+ optimize="true"
+ debug="true"
+ doc="${output.dir}​Sin.Smoketest.xml"
+ warninglevel="0">
+ <sources>
+ <include name="*.cs" />
+ </sources>
+ <references>
+ <include name="Sin.Library.dll" />
+ </references>
+ <lib>
+ <include name="${output.dir}" />
+ </lib>
+ </csc>
+ </target>
+
+</project>
  _____

Added: branches/0.1/Sin.Smo​ketest/Main.cs
--- branches/0.1/Sin.Smo​ketest/Main.cs 2005-12-18 12:49:43 UTC (rev
566)
+++ branches/0.1/Sin.Smo​ketest/Main.cs 2005-12-18 17:14:24 UTC (rev
567)
@@ -0,0 +1,71 @@

+/*
+ * Copyright (C) 2005 Casper S. Hornstrup
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ */
+using System;
+using System.IO;
+using System.Configuration;
+using Sin.Library;
+
+namespace Sin.Smoketest
+{
+ class MainClass
+ {
+ private static string SubversionRepository
+ {
+ get
+ {
+ return
ConfigurationSetting​s.AppSettings["subve​rsionRepository"];
+ }
+ }
+
+ private static string SubversionUserName
+ {
+ get
+ {
+ return
ConfigurationSetting​s.AppSettings["subve​rsionUserName"];
+ }
+ }
+
+ private static string SubversionPassword
+ {
+ get
+ {
+ return
ConfigurationSetting​s.AppSettings["subve​rsionPassword"];
+ }
+ }
+
+ private static void CommitChange(string branch)
+ {
+ IRepository repository = new
SubversionRepository(null,
+
SubversionRepository,
+
SubversionUserName,
+
SubversionPassword);
+ string branchLocation =
repository.GetBranch​Location(branch, BranchType.Checkin);
+ Revision newRevision;
+
repository.CreateRep​ositoryDirectory(bra​nchLocation,
+
"Smoketest",
+ out
newRevision);
+ }
+
+ public static void Main(string[] args)
+ {
+ string branch = Guid.NewGuid().ToString();
+ Console.WriteLine("Creating checkin branch
{0}...", branch);
+ CommitChange(branch);
+ }
+ }
+}
  _____

Added: branches/0.1/Sin.Smo​ketest/Sin.Smoketest​.cmbx
--- branches/0.1/Sin.Smo​ketest/Sin.Smoketest​.cmbx 2005-12-18
12:49:43 UTC (rev 566)
+++ branches/0.1/Sin.Smo​ketest/Sin.Smoketest​.cmbx 2005-12-18
17:14:24 UTC (rev 567)
@@ -0,0 +1,16 @@

+<Combine fileversion="1.0" name="Sin.Smoketest" description="">
+ <StartMode startupentry="Sin.Smoketest" single="True">
+ <Execute entry="Sin.Smoketest" type="None" />
+ </StartMode>
+ <Entries>
+ <Entry filename=".\Sin.Smoketest.prjx" />
+ </Entries>
+ <Configurations active="Debug">
+ <Configuration name="Release">
+ <Entry name="Sin.Smoketest" configurationname="Debug"
build="False" />
+ </Configuration>
+ <Configuration name="Debug">
+ <Entry name="Sin.Smoketest" configurationname="Debug"
build="False" />
+ </Configuration>
+ </Configurations>
+</Combine>
\ No newline at end of file
  _____

Added: branches/0.1/Sin.Smo​ketest/Sin.Smoketest​.prjx
--- branches/0.1/Sin.Smo​ketest/Sin.Smoketest​.prjx 2005-12-18
12:49:43 UTC (rev 566)
+++ branches/0.1/Sin.Smo​ketest/Sin.Smoketest​.prjx 2005-12-18
17:14:24 UTC (rev 567)
@@ -0,0 +1,28 @@

+<Project name="Sin.Smoketest" standardNamespace="S​in.Smoketest"
description="" newfilesearch="None" enableviewstate="True" version="1.1"
projecttype="C#">
+ <Contents>
+ <File name=".\Main.cs" subtype="Code" buildaction="Compile"
dependson="" data="" />
+ <File name=".\AssemblyInfo.cs" subtype="Code" buildaction="Compile"
dependson="" data="" />
+ <File name=".\Default.build" subtype="Code" buildaction="Nothing"
dependson="" data="" />
+ </Contents>
+ <References>
+ <Reference type="Project" refto="Sin.Library" localcopy="True" />
+ </References>
+ <DeploymentInformation target="" script="" strategy="File" />
+ <Configuration runwithwarnings="True" name="Debug">
+ <CodeGeneration runtime="MsNet" compiler="Csc" compilerversion=""
warninglevel="4" nowarn="" includedebuginformation="True"
optimize="False" unsafecodeallowed="False" generateoverflowchecks="True"
mainclass="" target="Exe" definesymbols=""
generatexmldocumenta​tion="False" win32Icon="" noconfig="False"
nostdlib="False" />
+ <Execution commandlineparameters="" consolepause="True" />
+ <Output directory=".\bin\Debug" assembly="Sin.Smoketest"
executeScript="" executeBeforeBuild="" executeAfterBuild=""
executeBeforeBuildArguments="" executeAfterBuildArguments="" />
+ </Configuration>
+ <Configurations active="Debug">
+ <Configuration runwithwarnings="True" name="Debug">
+ <CodeGeneration runtime="MsNet" compiler="Csc" compilerversion=""
warninglevel="4" nowarn="" includedebuginformation="True"
optimize="False" unsafecodeallowed="False" generateoverflowchecks="True"
mainclass="" target="Exe" definesymbols=""
generatexmldocumenta​tion="False" win32Icon="" noconfig="False"
nostdlib="False" />
+ <Execution commandlineparameters="" consolepause="True" />
+ <Output directory=".\bin\Debug" assembly="Sin.Smoketest"
executeScript="" executeBeforeBuild="" executeAfterBuild=""
executeBeforeBuildArguments="" executeAfterBuildArguments="" />
+ </Configuration>
+ <Configuration runwithwarnings="True" name="Release">
+ <CodeGeneration runtime="MsNet" compiler="Csc" compilerversion=""
warninglevel="4" nowarn="" includedebuginformation="False"
optimize="True" unsafecodeallowed="False" generateoverflowchecks="False"
mainclass="" target="Exe" definesymbols=""
generatexmldocumenta​tion="False" win32Icon="" noconfig="False"
nostdlib="False" />
+ <Execution commandlineparameters="" consolepause="True" />
+ <Output directory=".\bin\Release" assembly="Sin.Smoketest"
executeScript="" executeBeforeBuild="" executeAfterBuild=""
executeBeforeBuildArguments="" executeAfterBuildArguments="" />
+ </Configuration>
+ </Configurations>
+</Project>
\ No newline at end of file
  _____

Modified: branches/0.1/Sin.cmbx
--- branches/0.1/Sin.cmbx 2005-12-18 17:14:24 UTC (rev 567)
+++ branches/0.1/Sin.cmbx 2005-12-18 17:20:10 UTC (rev 568)
@@ -20,6 +20,7 @@

     <Execute entry="Sin.Tray" type="None" />
     <Execute entry="Sin.Library" type="None" />
     <Execute entry="Sin.Control" type="None" />
+ <Execute entry="Sin.Smoketest" type="None" />
   </StartMode>
   <Entries>
     <Entry filename=".\Win32Se​curity\Win32Securit​y.prjx" />
@@ -42,6 +43,7 @@
     <Entry filename=".\Sin.Tra​y\Sin.Tray.prjx" />
     <Entry filename=".\Sin.Lib​rary\Sin.Library.pr​jx" />
     <Entry filename=".\Sin.Con​trol\Sin.Control.pr​jx" />
+ <Entry filename=".\Sin.Smo​ketest\Sin.Smoketes​t.prjx" />
   </Entries>
   <Configurations active="Debug">
     <Configuration name="Release">
@@ -66,6 +68,7 @@
       <Entry name="Sin.Tray" configurationname="Debug" build="False" />
       <Entry name="Sin.Library" configurationname="Debug" build="False"
/>
       <Entry name="Sin.Control" configurationname="Debug" build="False"
/>
+ <Entry name="Sin.Smoketest" configurationname="Debug"
build="False" />
     </Configuration>
     <Configuration name="Debug">
       <Entry name="Win32Security" configurationname="Debug"
build="False" />
@@ -89,6 +92,7 @@
       <Entry name="Sin.Tray" configurationname="Debug" build="False" />
       <Entry name="Sin.Library" configurationname="Debug" build="False"
/>
       <Entry name="Sin.Control" configurationname="Debug" build="False"
/>
+ <Entry name="Sin.Smoketest" configurationname="Debug"
build="False" />
     </Configuration>
   </Configurations>
 </Combine>
\ No newline at end of file
Attachments

« Previous message in topic | 1 of 1 | Next message in topic »

Messages

Show all messages in topic

[chorns] 568: Smoketest target chorns Casper Hornstrup 2005-12-18 09:20:54 PST
Messages per page: