Skip to content
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

Running Build.ps1 locally #174

Closed
JoshKeegan opened this issue May 2, 2019 · 4 comments
Closed

Running Build.ps1 locally #174

JoshKeegan opened this issue May 2, 2019 · 4 comments
Assignees
Labels
question Further information is requested

Comments

@JoshKeegan
Copy link
Contributor

JoshKeegan commented May 2, 2019

Hi,
I'm trying to run Build.ps1 locally but see there are environment variables that need setting from .env. Should these be being loaded by the build script or should I be adding them first?
Cheers,
Josh

@unaizorrilla
Copy link
Collaborator

Hi @JoshKeegan

You don't need to do nothing! Is not working for you?

@unaizorrilla unaizorrilla added the question Further information is requested label May 3, 2019
@unaizorrilla unaizorrilla self-assigned this May 3, 2019
@JoshKeegan
Copy link
Contributor Author

I've submitted a PR #178 for an issue I had with getting it to start the dependencies.

I have also had to increase the amount of memory I give the Docker VM (and stop most of my own docker containers to free up memory). It looks like localstack is consuming ~4.7GiB of RAM. Is that to be expected?

image

I also then still get 3 tests failing:

PS C:\code\AspNetCore.Diagnostics.HealthChecks> .\build.ps1
  Restoring packages for C:\code\AspNetCore.Diagnostics.HealthChecks\samples\HealthChecks.UI.Sample\HealthChecks.UI.Sample.csproj...
  Restoring packages for C:\code\AspNetCore.Diagnostics.HealthChecks\samples\HealthChecks.UIAndApiCustomization\HealthChecks.UIAndApiCustomization.csproj...
  Restoring packages for C:\code\AspNetCore.Diagnostics.HealthChecks\samples\HealthChecks.UIAndApi\HealthChecks.UIAndApi.csproj...
  Restoring packages for C:\code\AspNetCore.Diagnostics.HealthChecks\samples\HealthChecks.Sample\HealthChecks.Sample.csproj...
  Restore completed in 144.99 ms for C:\code\AspNetCore.Diagnostics.HealthChecks\src\HealthChecks.Aws.S3\HealthChecks.Aws.S3.csproj.
  Restore completed in 146.97 ms for C:\code\AspNetCore.Diagnostics.HealthChecks\src\HealthChecks.AzureKeyVault\HealthChecks.AzureKeyVault.csproj.
  Restore completed in 146.97 ms for C:\code\AspNetCore.Diagnostics.HealthChecks\src\HealthChecks.AzureServiceBus\HealthChecks.AzureServiceBus.csproj.
  Restore completed in 144.99 ms for C:\code\AspNetCore.Diagnostics.HealthChecks\src\HealthChecks.AzureStorage\HealthChecks.AzureStorage.csproj.
  Restore completed in 9.15 ms for C:\code\AspNetCore.Diagnostics.HealthChecks\src\HealthChecks.Consul\HealthChecks.Consul.csproj.
  Restore completed in 7.4 ms for C:\code\AspNetCore.Diagnostics.HealthChecks\src\HealthChecks.Elasticsearch\HealthChecks.Elasticsearch.csproj.
  Restore completed in 8.79 ms for C:\code\AspNetCore.Diagnostics.HealthChecks\src\HealthChecks.DynamoDb\HealthChecks.DynamoDb.csproj.
  Restore completed in 28.37 ms for C:\code\AspNetCore.Diagnostics.HealthChecks\src\HealthChecks.CosmosDb\HealthChecks.CosmosDb.csproj.
  Restore completed in 36.25 ms for C:\code\AspNetCore.Diagnostics.HealthChecks\src\HealthChecks.DocumentDb\HealthChecks.DocumentDb.csproj.
  Restore completed in 19.21 ms for C:\code\AspNetCore.Diagnostics.HealthChecks\src\HealthChecks.EventStore\HealthChecks.EventStore.csproj.
  Restore completed in 33.12 ms for C:\code\AspNetCore.Diagnostics.HealthChecks\src\HealthChecks.IdSvr\HealthChecks.IdSvr.csproj.
  Restore completed in 52.35 ms for C:\code\AspNetCore.Diagnostics.HealthChecks\src\HealthChecks.Gcp.CloudFirestore\HealthChecks.Gcp.CloudFirestore.csproj.
  Restore completed in 10.59 ms for C:\code\AspNetCore.Diagnostics.HealthChecks\src\HealthChecks.Kafka\HealthChecks.Kafka.csproj.
  Restore completed in 13.93 ms for C:\code\AspNetCore.Diagnostics.HealthChecks\src\HealthChecks.Hangfire\HealthChecks.Hangfire.csproj.
  Restore completed in 18.98 ms for C:\code\AspNetCore.Diagnostics.HealthChecks\src\HealthChecks.MySql\HealthChecks.MySql.csproj.
  Restore completed in 22.5 ms for C:\code\AspNetCore.Diagnostics.HealthChecks\src\HealthChecks.MongoDb\HealthChecks.MongoDb.csproj.
  Restore completed in 14.38 ms for C:\code\AspNetCore.Diagnostics.HealthChecks\src\HealthChecks.Network\HealthChecks.Network.csproj.
  Restore completed in 20.73 ms for C:\code\AspNetCore.Diagnostics.HealthChecks\src\HealthChecks.Kubernetes\HealthChecks.Kubernetes.csproj.
  Restore completed in 8.23 ms for C:\code\AspNetCore.Diagnostics.HealthChecks\src\HealthChecks.NpgSql\HealthChecks.NpgSql.csproj.
  Restore completed in 18.21 ms for C:\code\AspNetCore.Diagnostics.HealthChecks\src\HealthChecks.Oracle\HealthChecks.Oracle.csproj.
  Restore completed in 6.8 ms for C:\code\AspNetCore.Diagnostics.HealthChecks\src\HealthChecks.Publisher.Seq\HealthChecks.Publisher.Seq.csproj.
  Restore completed in 11.79 ms for C:\code\AspNetCore.Diagnostics.HealthChecks\src\HealthChecks.Publisher.ApplicationInsights\HealthChecks.Publisher.ApplicationInsights.csproj.
  Restore completed in 22 ms for C:\code\AspNetCore.Diagnostics.HealthChecks\src\HealthChecks.RabbitMQ\HealthChecks.RabbitMQ.csproj.
  Restore completed in 11.7 ms for C:\code\AspNetCore.Diagnostics.HealthChecks\src\HealthChecks.RavenDB\HealthChecks.RavenDB.csproj.
  Restore completed in 12.48 ms for C:\code\AspNetCore.Diagnostics.HealthChecks\src\HealthChecks.Publisher.Prometheus\HealthChecks.Publisher.Prometheus.csproj.
  Restore completed in 14.12 ms for C:\code\AspNetCore.Diagnostics.HealthChecks\src\HealthChecks.Redis\HealthChecks.Redis.csproj.
  Restore completed in 26.4 ms for C:\code\AspNetCore.Diagnostics.HealthChecks\src\HealthChecks.Sqlite\HealthChecks.Sqlite.csproj.
  Restore completed in 32.81 ms for C:\code\AspNetCore.Diagnostics.HealthChecks\src\HealthChecks.SignalR\HealthChecks.SignalR.csproj.
  Restore completed in 24.58 ms for C:\code\AspNetCore.Diagnostics.HealthChecks\src\HealthChecks.System\HealthChecks.System.csproj.
  Restore completed in 20.06 ms for C:\code\AspNetCore.Diagnostics.HealthChecks\src\HealthChecks.SqlServer\HealthChecks.SqlServer.csproj.
  Restore completed in 15.62 ms for C:\code\AspNetCore.Diagnostics.HealthChecks\src\HealthChecks.UI.Client\HealthChecks.UI.Client.csproj.
  Restore completed in 20.33 ms for C:\code\AspNetCore.Diagnostics.HealthChecks\src\HealthChecks.Uris\HealthChecks.Uris.csproj.
  Restore completed in 34.53 ms for C:\code\AspNetCore.Diagnostics.HealthChecks\src\HealthChecks.UI\HealthChecks.UI.csproj.
  Restore completed in 65.9 ms for C:\code\AspNetCore.Diagnostics.HealthChecks\test\FunctionalTests\FunctionalTests.csproj.
  Restore completed in 29.6 ms for C:\code\AspNetCore.Diagnostics.HealthChecks\test\UnitTests\UnitTests.csproj.
  Restore completed in 3.7 sec for C:\code\AspNetCore.Diagnostics.HealthChecks\samples\HealthChecks.UI.Sample\HealthChecks.UI.Sample.csproj.
  Restore completed in 3.7 sec for C:\code\AspNetCore.Diagnostics.HealthChecks\samples\HealthChecks.UIAndApi\HealthChecks.UIAndApi.csproj.
  Restore completed in 3.7 sec for C:\code\AspNetCore.Diagnostics.HealthChecks\samples\HealthChecks.UIAndApiCustomization\HealthChecks.UIAndApiCustomization.csproj.
  Restore completed in 3.7 sec for C:\code\AspNetCore.Diagnostics.HealthChecks\samples\HealthChecks.Sample\HealthChecks.Sample.csproj.
build: Tag is
build: Package version suffix is ci-local
build: Build version suffix is ci-local-44716e3

Build succeeded.
    0 Warning(s)
    0 Error(s)

Time Elapsed 00:00:34.95
Running unit tests
Build started, please wait...
Build completed.

Test run for C:\code\AspNetCore.Diagnostics.HealthChecks\test\UnitTests\bin\Debug\netcoreapp2.2\UnitTests.dll(.NETCoreApp,Version=v2.2)
Microsoft (R) Test Execution Command Line Tool Version 15.9.0
Copyright (c) Microsoft Corporation.  All rights reserved.

Starting test execution, please wait...

Total tests: 78. Passed: 78. Failed: 0. Skipped: 0.
Test Run Successful.
Test execution time: 3.0546 Seconds
Starting aspnetcorediagnosticshealthchecks_elasticsearch_1 ...
Starting aspnetcorediagnosticshealthchecks_elasticsearch_1 ... done
Starting aspnetcorediagnosticshealthchecks_redis_1         ... done
Starting aspnetcorediagnosticshealthchecks_eventstore_1    ... done
Starting aspnetcorediagnosticshealthchecks_rabbitmq_1      ... done
Starting aspnetcorediagnosticshealthchecks_consul_1        ... done
Starting aspnetcorediagnosticshealthchecks_idsvr_1         ... done
Starting aspnetcorediagnosticshealthchecks_postgres_1      ... done
Starting aspnetcorediagnosticshealthchecks_localstack_1    ... done
Starting aspnetcorediagnosticshealthchecks_mysql_1         ... done
Starting aspnetcorediagnosticshealthchecks_zookeeper_1     ... done
Starting aspnetcorediagnosticshealthchecks_oracle_1        ... done
Starting aspnetcorediagnosticshealthchecks_ftp_1           ... done
Starting mail                                              ... done
Starting aspnetcorediagnosticshealthchecks_mongodb_1       ... done
Starting aspnetcorediagnosticshealthchecks_sftp_1          ... done
Starting aspnetcorediagnosticshealthchecks_kafka_1         ... done
compose up done
Running functional tests
Build started, please wait...
Build completed.

Test run for C:\code\AspNetCore.Diagnostics.HealthChecks\test\FunctionalTests\bin\Debug\netcoreapp2.2\FunctionalTests.dll(.NETCoreApp,Version=v2.2)
Microsoft (R) Test Execution Command Line Tool Version 15.9.0
Copyright (c) Microsoft Corporation.  All rights reserved.

Starting test execution, please wait...
[xUnit.net 00:00:17.68]     FunctionalTests.HealthChecks.Uris.uri_healthcheck_should.be_healthy_if_request_sucess_and_timeout_is_configured [FAIL]
Failed   FunctionalTests.HealthChecks.Uris.uri_healthcheck_should.be_healthy_if_request_sucess_and_timeout_is_configured
Error Message:
 Expected object to be OK, but found ServiceUnavailable.
Stack Trace:
   at FluentAssertions.Execution.XUnit2TestFramework.Throw(String message) in C:\projects\fluentassertions-vf06b\Src\FluentAssertions\Execution\XUnit2TestFramework.cs:line 32
   at FluentAssertions.Execution.AssertionScope.FailWith(Func`1 failReasonFunc) in C:\projects\fluentassertions-vf06b\Src\FluentAssertions\Execution\AssertionScope.cs:line 181
   at FluentAssertions.Primitives.ObjectAssertions.Be(Object expected, String because, Object[] becauseArgs) in C:\projects\fluentassertions-vf06b\Src\FluentAssertions\Primitives\ObjectAssertions.cs:line 38
   at FunctionalTests.HealthChecks.Uris.uri_healthcheck_should.be_healthy_if_request_sucess_and_timeout_is_configured() in C:\code\AspNetCore.Diagnostics.HealthChecks\test\FunctionalTests\HealthChecks.Uris\UriHealthCheckTests.cs:line 267
--- End of stack trace from previous location where exception was thrown ---
[xUnit.net 00:01:04.11]     be healthy if ravendb is available and contains specific database [FAIL]
Failed   be healthy if ravendb is available and contains specific database
Error Message:
 Expected object to be OK, but found ServiceUnavailable.
Stack Trace:
   at FluentAssertions.Execution.XUnit2TestFramework.Throw(String message) in C:\projects\fluentassertions-vf06b\Src\FluentAssertions\Execution\XUnit2TestFramework.cs:line 32
   at FluentAssertions.Execution.AssertionScope.FailWith(Func`1 failReasonFunc) in C:\projects\fluentassertions-vf06b\Src\FluentAssertions\Execution\AssertionScope.cs:line 181
   at FluentAssertions.Primitives.ObjectAssertions.Be(Object expected, String because, Object[] becauseArgs) in C:\projects\fluentassertions-vf06b\Src\FluentAssertions\Primitives\ObjectAssertions.cs:line 38
   at FunctionalTests.HealthChecks.RavenDB.ravendb_with_options_healthcheck_should.be_healthy_if_ravendb_is_available_and_contains_specific_database() in C:\code\AspNetCore.Diagnostics.HealthChecks\test\FunctionalTests\HealthChecks.RavenDB\RavenDBWithOptionsHealthCheckTests.cs:line 83
--- End of stack trace from previous location where exception was thrown ---
[xUnit.net 00:01:10.09]     be healthy if ravendb is available and contains specific database [FAIL]
Failed   be healthy if ravendb is available and contains specific database
Error Message:
 Expected object to be OK, but found ServiceUnavailable.
Stack Trace:
   at FluentAssertions.Execution.XUnit2TestFramework.Throw(String message) in C:\projects\fluentassertions-vf06b\Src\FluentAssertions\Execution\XUnit2TestFramework.cs:line 32
   at FluentAssertions.Execution.AssertionScope.FailWith(Func`1 failReasonFunc) in C:\projects\fluentassertions-vf06b\Src\FluentAssertions\Execution\AssertionScope.cs:line 181
   at FluentAssertions.Primitives.ObjectAssertions.Be(Object expected, String because, Object[] becauseArgs) in C:\projects\fluentassertions-vf06b\Src\FluentAssertions\Primitives\ObjectAssertions.cs:line 38
   at FunctionalTests.HealthChecks.RavenDB.ravendb_with_single_connection_string_healthcheck_should.be_healthy_if_ravendb_is_available_and_contains_specific_database() in C:\code\AspNetCore.Diagnostics.HealthChecks\test\FunctionalTests\HealthChecks.RavenDB\RavenDBWithSingleConnectionStringHealthCheckTests.cs:line 80
--- End of stack trace from previous location where exception was thrown ---
[xUnit.net 00:03:10.51]     FunctionalTests.HealthChecks.Network.smtp_healthcheck_should.be_healthty_when_login_with_plain_smtp [SKIP]
Skipped  FunctionalTests.HealthChecks.Network.smtp_healthcheck_should.be_healthty_when_login_with_plain_smtp

Total tests: 99. Passed: 95. Failed: 3. Skipped: 1.
Test Run Failed.
Test execution time: 3.2275 Minutes
Exec:
At C:\code\AspNetCore.Diagnostics.HealthChecks\build.ps1:21 char:9
+         throw ("Exec: " + $errorMessage)
+         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : OperationStopped: (Exec: :String) [], RuntimeException
    + FullyQualifiedErrorId : Exec:

@JoshKeegan
Copy link
Contributor Author

Update: I have ran this again a few times and get between 2-4 failures. The Raven DB tests always fail, and the URI tests seem to be flickering.

@unaizorrilla
Copy link
Collaborator

I need to work on ravendb tests because its depend on cloud service and the state is not consistent. Uri’s works well in my side.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants