Skip to content

Commit

Permalink
Remove mcr.microsoft.com/azure-sql-edge support
Browse files Browse the repository at this point in the history
  • Loading branch information
cagrin committed Sep 19, 2024
1 parent f0f1fd6 commit 667ea95
Show file tree
Hide file tree
Showing 6 changed files with 11 additions and 35 deletions.
3 changes: 1 addition & 2 deletions .github/workflows/onPushMain.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,11 @@ on:
- main

jobs:
test-edge:
test-mssql:
runs-on: ubuntu-latest
strategy:
matrix:
include:
- image: mcr.microsoft.com/azure-sql-edge
- image: mcr.microsoft.com/mssql/server:2019-latest
- image: mcr.microsoft.com/mssql/server:2022-latest
steps:
Expand Down
31 changes: 4 additions & 27 deletions NOTES.md
Original file line number Diff line number Diff line change
@@ -1,33 +1,10 @@
## Create Azure SQL Edge instance in docker
```
docker run -e 'ACCEPT_EULA=1' -e 'MSSQL_SA_PASSWORD=A.794613' -e 'MSSQL_COLLATION=SQL_Latin1_General_CP1_CI_AS' -p 51433:1433 -d mcr.microsoft.com/azure-sql-edge
```

## Build and publish project Tests to localhost
```
dotnet publish ./latest/tSQLt.Edge.Tests /p:TargetServerName=localhost /p:TargetPort=51433 /p:TargetDatabaseName=tSQLt.Edge.Tests /p:TargetUser=sa /p:TargetPassword=A.794613
```

## Prepare Powershell (optional)
```
pwsh
Set-PSRepository PSGallery -InstallationPolicy Trusted
Install-Module -Name SqlServer
```

## Run unit tests in Powershell
```
pwsh
Invoke-Sqlcmd -Query "EXEC tSQLt.RunAll" -ServerInstance "localhost,51433" -Database "tSQLt.Edge.Tests" -Username "sa" -Password "A.794613"
```

## Run unit tests on Dev Container
```
git submodule update --init
sqltest runall --image mcr.microsoft.com/azure-sql-edge --project ./latest/tSQLt.Edge.Tests --cc-include-tsqlt
sqltest runall --image mcr.microsoft.com/azure-sql-edge --project ./latest/tSQLt.Edge.Tests.CaseSensitive --cc-include-tsqlt
sqltest runall --image mcr.microsoft.com/azure-sql-edge --project ./latest/tSQLt.Original.Tests --cc-disable
sqltest runall --image mcr.microsoft.com/azure-sql-edge --project ./current/Example.Tests
sqltest runall --image mcr.microsoft.com/mssql/server:2019-latest --project ./latest/tSQLt.Edge.Tests --cc-include-tsqlt
sqltest runall --image mcr.microsoft.com/mssql/server:2019-latest --project ./latest/tSQLt.Edge.Tests.CaseSensitive --cc-include-tsqlt
sqltest runall --image mcr.microsoft.com/mssql/server:2019-latest --project ./latest/tSQLt.Original.Tests --cc-disable
sqltest runall --image mcr.microsoft.com/mssql/server:2019-latest --project ./current/Example.Tests
dotnet test ./latest/tSQLt.XmlResult.Tests
sqltest runall --image mcr.microsoft.com/mssql/server:2019-latest --project ./legacy/tSQLt.Unoriginal.Tests --cc-disable
sqltest runall --image mcr.microsoft.com/mssql/server:2019-latest --project ./legacy/Example.Tests
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
[![Nuget](https://img.shields.io/nuget/dt/tSQLt.Edge)](https://www.nuget.org/stats/packages/tSQLt.Edge?groupby=Version)

# tSQLt-edge
tSQLt-compatible unit testing framework for Azure SQL Edge, SQL Server 2019 and 2022. It is available as a [nuget package](https://www.nuget.org/packages/tSQLt.Edge) and works perfectly with [MSBuild.SDK.SqlProj](https://github.com/rr-wfm/MSBuild.Sdk.SqlProj) project format.
tSQLt-compatible unit testing framework for SQL Server 2019 and 2022. It is available as a [nuget package](https://www.nuget.org/packages/tSQLt.Edge) and works perfectly with [MSBuild.SDK.SqlProj](https://github.com/rr-wfm/MSBuild.Sdk.SqlProj) project format.

## Description
This project was created in order to practice code writing in TDD. Here are some detailed principles I was followed:
Expand Down
4 changes: 2 additions & 2 deletions current/Example.Tests/Example.Tests.csproj
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
<Project Sdk="MSBuild.Sdk.SqlProj/2.7.1">
<PropertyGroup>
<TargetFramework>netstandard2.0</TargetFramework>
<SqlServerVersion>SqlAzure</SqlServerVersion>
<SqlServerVersion>Sql150</SqlServerVersion>
</PropertyGroup>
<ItemGroup>
<ProjectReference Include="..\Example\Example.csproj" />
</ItemGroup>
<ItemGroup>
<PackageReference Include="Microsoft.SqlServer.Dacpacs.Azure.Master" Version="160.0.0" DacpacName="master" DatabaseVariableLiteralValue="master" />
<PackageReference Include="Microsoft.SqlServer.Dacpacs.Master" Version="150.0.0" DacpacName="master" DatabaseVariableLiteralValue="master" />
</ItemGroup>
<ItemGroup>
<PackageReference Include="tSQLt.Edge" Version="0.9.7" />
Expand Down
4 changes: 2 additions & 2 deletions current/Example/Example.csproj
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
<Project Sdk="MSBuild.Sdk.SqlProj/2.7.1">
<PropertyGroup>
<TargetFramework>netstandard2.0</TargetFramework>
<SqlServerVersion>SqlAzure</SqlServerVersion>
<SqlServerVersion>Sql150</SqlServerVersion>
<RunSqlCodeAnalysis>True</RunSqlCodeAnalysis>
<CodeAnalysisRules>-SqlServer.Rules.SRP0005;-Smells.SML030</CodeAnalysisRules>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="Microsoft.SqlServer.Dacpacs.Azure.Master" Version="160.0.0" DacpacName="master" DatabaseVariableLiteralValue="master" />
<PackageReference Include="Microsoft.SqlServer.Dacpacs.Master" Version="150.0.0" DacpacName="master" DatabaseVariableLiteralValue="master" />
</ItemGroup>
</Project>
2 changes: 1 addition & 1 deletion latest/tSQLt.Edge/tSQLt.Edge.nuspec
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<id>tSQLt.Edge</id>
<title></title>
<authors>Krzysztof Strugiński</authors>
<description>tSQLt-compatible unit testing framework for Azure SQL Edge, SQL Server 2019 and 2022.</description>
<description>tSQLt-compatible unit testing framework for SQL Server 2019 and 2022.</description>
<owners>cagrin</owners>
<requireLicenseAcceptance>false</requireLicenseAcceptance>
<license type="file">LICENSE</license>
Expand Down

0 comments on commit 667ea95

Please sign in to comment.