This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public abstract class BaseApiTestsFixture : IDisposable | |
{ | |
protected bool Disposed; | |
public TestServer Server { get; } | |
public Mock<ILogger> MockLogger { get; } | |
public IConfigurationRoot Configuration { get; } | |
public int TimeoutInMilliseconds { get; } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class BaseServiceClientTests<TFixture, TServiceClient> | |
where TFixture : BaseApiTestsFixture, new() | |
where TServiceClient : BaseClient | |
{ | |
protected readonly TFixture Fixture; | |
protected readonly TServiceClient ServiceClient; | |
protected BaseServiceClientTests(TFixture fixture) | |
{ | |
Fixture = fixture; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[CollectionDefinition(nameof(ApiTestsCollection))] | |
public class ApiTestsCollection : ICollectionFixture<BaseApiTestsFixture<TestsStartup>> | |
{ | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[Collection(nameof(ApiTestsCollection))] | |
public class ValuesControllerTests : BaseServiceClientTests<BaseApiTestsFixture<TestsStartup>, ValuesServiceClient> | |
{ | |
public ValuesControllerTests(BaseApiTestsFixture<TestsStartup> fixture) : base(fixture) | |
{ | |
} | |
[Fact] | |
public void ShouldReturnValues() | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
/opt/mssql/bin/sqlservr --force-setup -q $MSSQL_COLLATION & | |
pid=$! | |
FILE_TO_WATCH=/var/opt/mssql/log/errorlog | |
SEARCH_PATTERN="Recovery is complete" | |
cat $FILE_TO_WATCH | grep -qe "$SEARCH_PATTERN" | |
while [[ $? != 0 ]]; do |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM microsoft/mssql-server-linux:latest | |
LABEL project.url="https://github.com/litichevskiydv/MsSqlTools" | |
COPY setup.sh / | |
RUN chmod 777 setup.sh | |
ENV MSSQL_COLLATION=Cyrillic_General_CI_AS | |
CMD ./setup.sh && /opt/mssql/bin/sqlservr |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
namespace ImageValidator | |
{ | |
using System; | |
using System.IO; | |
using System.Linq; | |
using System.Reflection; | |
using System.Threading; | |
using Dapper; | |
using JetBrains.Annotations; | |
using Microsoft.Extensions.Configuration; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
language: csharp | |
env: | |
- IMAGE_TAG=latest | |
services: | |
- docker | |
mono: none | |
dotnet: 1.0.4 | |
dist: trusty | |
branches: | |
only: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[HttpPost] | |
public async Task Post([FromBody] DockerRequest request) | |
{ | |
var body = @" | |
{ | |
""request"": { | |
""branch"":""<ImageValidatorBranch>"", | |
""config"": { | |
""env"": { | |
""IMAGE_TAG"": ""<ImageTag>"" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Target - The task you want to start. Runs the Default task if not specified. | |
var target = Argument("Target", "Default"); | |
// Configuration - The build configuration (Debug/Release) to use. | |
var configuration = | |
HasArgument("Configuration") | |
? Argument<string>("Configuration") | |
: EnvironmentVariable("Configuration") ?? "Release"; | |
// The build number to use in the version number of the built NuGet packages. |
OlderNewer