Skip to content

Updating branch #3

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 38 commits into from
Oct 11, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
38 commits
Select commit Hold shift + click to select a range
e83be05
added " around msbuild path
Mar 22, 2018
a65dcf6
test mentioning signingkey.pfx in build
Mar 22, 2018
384b268
.
Mar 22, 2018
f2980d3
removed cert name
Mar 22, 2018
9bf9f7e
added Import-PfxCert.ps script
Mar 22, 2018
9eeedd0
.
Mar 22, 2018
751c28d
replaced " with actual "
Mar 22, 2018
04aca84
added CI(NoSigning) Build Configuration
Jun 30, 2018
cfafbf2
Merge pull request #1 from tSQLt-org/master
martinisaksen Oct 16, 2018
cd6608a
Wrote Install Documentation for Build Process
Mar 16, 2019
96dc237
Changed the times on failing test in Tests/Run_Methods_Tests.class.sq…
Mar 16, 2019
f7f9c8d
Fixed several permission and side-effect issues in the build file.
Mar 16, 2019
2aa8fb5
updated Install the tSQLt build.docx
Mar 23, 2019
a78bd50
new SigningKey.pfx
May 29, 2019
2e4a16d
.
May 29, 2019
64d467f
no signing in project files
May 29, 2019
a71a406
removed SigningKey.pfx files
May 29, 2019
cff9e72
.
May 29, 2019
6be10ee
.
May 29, 2019
4b4fc26
Started conversion from NANT to ANT
May 31, 2019
45cd8a0
[ANT] got execute.sql.file working
Jun 1, 2019
70328e2
.
Jun 1, 2019
500cb4b
read version fixed
Jun 2, 2019
1d84bf9
ANT Build succeeds
Jun 3, 2019
ab3bdc4
.
Jun 4, 2019
6dda1ea
.
Jun 4, 2019
d3cb6ea
selective CLR signing
Jun 4, 2019
0e84ae3
local build successful (including signing)
Jun 5, 2019
ff813b8
.
Jun 5, 2019
00226d7
.
Jun 12, 2019
0b5a07c
.
Jun 12, 2019
c4b2b60
.
Jun 12, 2019
9fcc11f
.
Jun 12, 2019
7270498
creating tSQLt.zip now working on Azure DevOps
Jun 12, 2019
d965edd
Changed tests to handle new SQL 2017 error format
Jun 29, 2019
9f2d261
Fixed Build Failure on SQL Server 2017 due to SQL Server bug.
Jul 1, 2019
6fda42f
Merge pull request #2 from tSQLt-org/master
martinisaksen Oct 11, 2019
66a7b05
Merge branch 'TriggerHelpForSQLCover' into master
martinisaksen Oct 11, 2019
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -11,3 +11,11 @@
/tSQLtCLR/tSQLtExternalAccessKey/bin
/tSQLtCLR/tSQLtExternalAccessKey/obj
/tSQLtCLR/tSQLtCLR.v12.suo
*.dtbcache
*.suo
/tSQLtCLR/builderr.txt
/tSQLtCLR/buildlog.txt
/tSQLtCLR/.vs/tSQLtCLR/v15/Server/sqlite3/db.lock
/tSQLtCLR/.vs/tSQLtCLR/v15/Server/sqlite3/storage.ide
/tSQLtCLR/.vs/tSQLtCLR/v15/Server/sqlite3/storage.ide-shm
/tSQLtCLR/.vs/tSQLtCLR/v15/Server/sqlite3/storage.ide-wal
46 changes: 44 additions & 2 deletions Build/Build.ssmssqlproj
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<Items>
<LogicalFolder Name="Connections" Type="2" Sorted="true">
<Items>
<ConnectionNode Name="Dev_2014:MacWin7A\meinse00">
<ConnectionNode Name="Dev_2014:WIN10A\meinse00">
<Created>2014-12-31T18:06:01.9272147-05:00</Created>
<Type>SQL</Type>
<Server>Dev_2014</Server>
Expand All @@ -15,7 +15,7 @@
<ConnectionProtocol>NotSpecified</ConnectionProtocol>
<ApplicationName>Microsoft SQL Server Management Studio - Query</ApplicationName>
</ConnectionNode>
<ConnectionNode Name="Dev_tSQLt:MacWin7A\meinse00">
<ConnectionNode Name="Dev_tSQLt:WIN10A\meinse00">
<Created>2014-11-24T18:10:21.4587287-05:00</Created>
<Type>SQL</Type>
<Server>Dev_tSQLt</Server>
Expand Down Expand Up @@ -115,6 +115,12 @@
<AssociatedConnUserName />
<FullPath>Install(tSQLtExternalAccessKey).sql</FullPath>
</FileNode>
<FileNode Name="PrintVersionInfo.sql">
<AssociatedConnectionMoniker>8c91a03d-f9b4-46c0-a305-b5dcc79ff907:Dev_tSQLt:True</AssociatedConnectionMoniker>
<AssociatedConnSrvName>Dev_tSQLt</AssociatedConnSrvName>
<AssociatedConnUserName />
<FullPath>PrintVersionInfo.sql</FullPath>
</FileNode>
</Items>
</LogicalFolder>
<LogicalFolder Name="Miscellaneous" Type="3" Sorted="true">
Expand All @@ -137,6 +143,12 @@
<AssociatedConnUserName />
<FullPath>CreateAssemblyGenerator.exe</FullPath>
</FileNode>
<FileNode Name="Install the tSQLt build.docx">
<AssociatedConnectionMoniker />
<AssociatedConnSrvName />
<AssociatedConnUserName />
<FullPath>Install the tSQLt build.docx</FullPath>
</FileNode>
<FileNode Name="License.txt">
<AssociatedConnectionMoniker />
<AssociatedConnSrvName />
Expand Down Expand Up @@ -191,12 +203,42 @@
<AssociatedConnUserName />
<FullPath>SqlLoginNbuild.bat</FullPath>
</FileNode>
<FileNode Name="tSQLt.build.xml">
<AssociatedConnectionMoniker />
<AssociatedConnSrvName />
<AssociatedConnUserName />
<FullPath>tSQLt.build.xml</FullPath>
</FileNode>
<FileNode Name="tSQLt.buildCLR.xml">
<AssociatedConnectionMoniker />
<AssociatedConnSrvName />
<AssociatedConnUserName />
<FullPath>tSQLt.buildCLR.xml</FullPath>
</FileNode>
<FileNode Name="tSQLt.copybuild.xml">
<AssociatedConnectionMoniker />
<AssociatedConnSrvName />
<AssociatedConnUserName />
<FullPath>tSQLt.copybuild.xml</FullPath>
</FileNode>
<FileNode Name="tSQLt.experiments.build.xml">
<AssociatedConnectionMoniker />
<AssociatedConnSrvName />
<AssociatedConnUserName />
<FullPath>tSQLt.experiments.build.xml</FullPath>
</FileNode>
<FileNode Name="tSQLt.local_build_output.build">
<AssociatedConnectionMoniker />
<AssociatedConnSrvName />
<AssociatedConnUserName />
<FullPath>tSQLt.local_build_output.build</FullPath>
</FileNode>
<FileNode Name="tSQLt.validatebuild.xml">
<AssociatedConnectionMoniker />
<AssociatedConnSrvName />
<AssociatedConnUserName />
<FullPath>tSQLt.validatebuild.xml</FullPath>
</FileNode>
<FileNode Name="VersionInfo.vbs">
<AssociatedConnectionMoniker />
<AssociatedConnSrvName />
Expand Down
Binary file modified Build/CreateAssemblyGenerator.exe
Binary file not shown.
14 changes: 14 additions & 0 deletions Build/Import-PfxCert.ps1
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
param($PfxFilePath, $Password)

$absolutePfxFilePath = Resolve-Path -Path $PfxFilePath
Write-Output "Importing store certificate &#39;$absolutePfxFilePath&#39;..."

Add-Type -AssemblyName System.Security
$cert = New-Object System.Security.Cryptography.X509Certificates.X509Certificate2
$cert.Import($absolutePfxFilePath, $Password, [System.Security.Cryptography.X509Certificates.X509KeyStorageFlags]::PersistKeySet)
$store = new-object system.security.cryptography.X509Certificates.X509Store -argumentlist "MY", CurrentUser
$store.Open([System.Security.Cryptography.X509Certificates.OpenFlags]::"ReadWrite")
$store.Add($cert)
$store.Close()

#Source: http://blog.danskingdom.com/creating-a-pfx-certificate-and-applying-it-on-the-build-server-at-build-time/
Binary file added Build/Install the tSQLt build.docx
Binary file not shown.
39 changes: 38 additions & 1 deletion Build/LocalBuild.bat
Original file line number Diff line number Diff line change
@@ -1 +1,38 @@
cmd /C %1\bin\ant -Dmsbuild.path=%2 -Ddb.server=%3 -Ddb.name=%4 %5
@ECHO OFF

REM CALL %1\bin\ant -buildfile Build\tSQLt.experiments.build.xml -Dmsbuild.path=%2 -verbose || goto :error
REM goto :EOF

ECHO +-------------------------+
ECHO : Starting CLR BUILD :
ECHO +-------------------------+
CALL %1\bin\ant -buildfile Build\tSQLt.buildCLR.xml -Dmsbuild.path=%2 || goto :error

ECHO +-------------------------+
ECHO : Starting tSQLt BUILD :
ECHO +-------------------------+
CALL %1\bin\ant -buildfile Build\tSQLt.build.xml || goto :error

ECHO +-------------------------+
ECHO : Copying BUILD :
ECHO +-------------------------+
ECHO :- THIS STEP IS OPTIONAL -:
ECHO +-------------------------+
CALL %1\bin\ant -buildfile Build\tSQLt.copybuild.xml || goto :error

ECHO +-------------------------+
ECHO : Validating BUILD :
ECHO +-------------------------+
CALL %1\bin\ant -buildfile Build\tSQLt.validatebuild.xml -Ddb.version=%3 -Ddb.server=%4 -Ddb.name=%5 || goto :error

ECHO +-------------------------+
ECHO : BUILD SUCCEEDED :
ECHO +-------------------------+
goto :EOF

:error
ECHO +-------------------------+
ECHO : !!! BUILD FAILED !!! :
ECHO +-------------------------+
exit /b %errorlevel%

17 changes: 17 additions & 0 deletions Build/PrintVersionInfo.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
DECLARE @txt NVARCHAR(MAX);
IF(OBJECT_ID('tempdb..#VersionInfoTable')IS NOT NULL)DROP TABLE #VersionInfoTable;
SELECT Version, ClrVersion, ClrSigningKey INTO #VersionInfoTable FROM tSQLt.Info();
EXEC tSQLt.TableToText @txt = @txt OUTPUT, @TableName = N'#VersionInfoTable';

RAISERROR('+-----------------------------------------------------------------------------------------------------+',0,1)WITH NOWAIT;
RAISERROR('| tSQLt Info: |',0,1)WITH NOWAIT;
RAISERROR('+-----------------------------------------------------------------------------------------------------+',0,1)WITH NOWAIT;
RAISERROR('',0,1)WITH NOWAIT;
RAISERROR(@txt,0,1)WITH NOWAIT;
RAISERROR('',0,1)WITH NOWAIT;
RAISERROR('+-----------------------------------------------------------------------------------------------------+',0,1)WITH NOWAIT;
RAISERROR('| SQL Server Info: |',0,1)WITH NOWAIT;
RAISERROR('+-----------------------------------------------------------------------------------------------------+',0,1)WITH NOWAIT;
RAISERROR('',0,1)WITH NOWAIT;
RAISERROR('%s',0,1,@@VERSION)WITH NOWAIT;
RAISERROR('-------------------------------------------------------------------------------------------------------',0,1)WITH NOWAIT;
3 changes: 2 additions & 1 deletion Build/Setup.bat
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@
IF "%~1"=="" GOTO :Usage

CD /d %~p0
sqlcmd -S %1 -E -I -d master -i "ExecuteAsSA.sql" "tSQLtKey.sql" "Create(tSQLtKey).sql" "CreateLogin(tSQLt.Build).sql" -V11
REM sqlcmd -S %1 -E -I -d master -i "ExecuteAsSA.sql" "tSQLtKey.sql" "Create(tSQLtKey).sql" "CreateLogin(tSQLt.Build).sql" -V11
sqlcmd -S %1 -E -I -d master -i "CreateLogin(tSQLt.Build).sql" -V11
GOTO :EOF

:Usage
Expand Down
1 change: 1 addition & 0 deletions Build/Version.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
1.0.7093.9172
16 changes: 8 additions & 8 deletions Build/tSQLt.build
Original file line number Diff line number Diff line change
Expand Up @@ -49,10 +49,10 @@
</target>

<target name="clr.compile">
<echo message="Compile CLR Command: ${msbuild.path}msbuild.exe tSQLtCLR.csproj /p:Configuration=CruiseControl /nologo"/>
<echo message="Compile CLR Command: &quot;${msbuild.path}msbuild.exe&quot; tSQLtCLR.csproj /p:Configuration=CruiseControl /nologo"/>
<exec program="cmd" workingdir="../tSQLtCLR/tSQLtCLR/" failonerror="true">
<arg value="/c"/>
<arg value="${msbuild.path}msbuild.exe tSQLtCLR.csproj /p:Configuration=CruiseControl /nologo"/>
<arg value="&quot;${msbuild.path}msbuild.exe&quot; tSQLtCLR.csproj /p:Configuration=CruiseControl /nologo"/>
</exec>

<exec program="cmd" workingdir="." failonerror="true" output="temp/Version.txt">
Expand All @@ -72,10 +72,10 @@
</target>

<target name="tSQLtExternalAccessKey.compile">
<echo message="Compile CLR Command: ${msbuild.path}msbuild.exe tSQLtExternalAccessKey.csproj /p:Configuration=CruiseControl /nologo"/>
<echo message="Compile CLR Command: &quot;${msbuild.path}msbuild.exe&quot; tSQLtExternalAccessKey.csproj /p:Configuration=CruiseControl /nologo"/>
<exec program="cmd" workingdir="../tSQLtCLR/tSQLtExternalAccessKey/" failonerror="true">
<arg value="/c"/>
<arg value="${msbuild.path}msbuild.exe tSQLtExternalAccessKey.csproj /p:Configuration=CruiseControl /nologo"/>
<arg value="&quot;${msbuild.path}msbuild.exe&quot; tSQLtExternalAccessKey.csproj /p:Configuration=CruiseControl /nologo"/>
</exec>
</target>

Expand Down Expand Up @@ -169,18 +169,18 @@
</target>

<target name="clr.testutil.compile">
<echo message="Compile CLR Command: ${msbuild.path}msbuild.exe tSQLtTestUtilCLR.csproj /p:Configuration=CruiseControl /nologo"/>
<echo message="Compile CLR Command: &quot;${msbuild.path}msbuild.exe&quot; tSQLtTestUtilCLR.csproj /p:Configuration=CruiseControl /nologo"/>
<exec program="cmd" workingdir="../tSQLtCLR/tSQLtTestUtilCLR/" failonerror="true">
<arg value="/c"/>
<arg value="${msbuild.path}msbuild.exe tSQLtTestUtilCLR.csproj /p:Configuration=CruiseControl /nologo"/>
<arg value="&quot;${msbuild.path}msbuild.exe&quot; tSQLtTestUtilCLR.csproj /p:Configuration=CruiseControl /nologo"/>
</exec>
</target>

<target name="clr.UnsignedEmpty.compile">
<echo message="Compile CLR Command: ${msbuild.path}msbuild.exe UnsignedEmpty.csproj /p:Configuration=CruiseControl /nologo"/>
<echo message="Compile CLR Command: &quot;${msbuild.path}msbuild.exe&quot; UnsignedEmpty.csproj /p:Configuration=CruiseControl /nologo"/>
<exec program="cmd" workingdir="../tSQLtCLR/UnsignedEmpty/" failonerror="true">
<arg value="/c"/>
<arg value="${msbuild.path}msbuild.exe UnsignedEmpty.csproj /p:Configuration=CruiseControl /nologo"/>
<arg value="&quot;${msbuild.path}msbuild.exe&quot; UnsignedEmpty.csproj /p:Configuration=CruiseControl /nologo"/>
</exec>
</target>

Expand Down
Loading