Skip to content

Commit

Permalink
Merge pull request #1 from azure-devops-compliance/cleanup/removed-un…
Browse files Browse the repository at this point in the history
…used-data

cleanup(data): removed unused requests and responses
  • Loading branch information
wisses authored Nov 1, 2023
2 parents fcc21cd + 2c91d0d commit 5b130de
Show file tree
Hide file tree
Showing 19 changed files with 3 additions and 609 deletions.
53 changes: 2 additions & 51 deletions VstsService.Tests/Builds.cs
Original file line number Diff line number Diff line change
Expand Up @@ -17,43 +17,7 @@ public Builds(TestConfig config)
_config = config;
_client = new VstsRestClient(_config.Organization, _config.Token);
}

[Fact]
[Trait("category", "integration")]
public void QueryArtifacts()
{
var artifacts = _client.Get(Requests.Builds.Artifacts(_config.Project, _config.BuildId)).ToList();
artifacts.ShouldNotBeEmpty();

var artifact = artifacts.First();
artifact.Id.ShouldNotBe(0);

artifact.Resource.ShouldNotBeNull();
artifact.Resource.Type.ShouldBe("Container");
}

[Fact]
[Trait("category", "integration")]
public async Task QueryBuild()
{
var build = await _client.GetAsync(Requests.Builds.Build(_config.Project, _config.BuildId));
build.ShouldNotBeNull();
build.Id.ShouldNotBe(0);
build.Definition.ShouldNotBeNull();
build.Project.ShouldNotBeNull();
build.Result.ShouldNotBeNull();
}

[Fact]
[Trait("category", "integration")]
public void QueryLongRunningBuilds()
{
var queryOrder = "startTimeAscending";
var minTime = DateTime.UtcNow.AddHours(-6).ToString("O");
var build = _client.Get(Requests.Builds.LongRunningBuilds(_config.Project, queryOrder, minTime)).ToList();
build.ShouldNotBeNull();
}


[Fact]
[Trait("category", "integration")]
public async Task QueryBuildDefinition()
Expand Down Expand Up @@ -93,20 +57,7 @@ public async Task QueryBuildDefinitionsReturnsBuildDefinitionsWithExtendedProper
buildDefinitions.ShouldNotBeNull();
buildDefinitions.SelectTokens("value[*].process").Count().ShouldBeGreaterThan(0);
}

[Fact]
[Trait("category", "integration")]
public async Task CanQueryBuildDefinitionsByProcessType()
{
var projectId = (await _client.GetAsync(Project.Properties(_config.Project))).Id;

var buildDefinitions = _client.Get(Requests.Builds.BuildDefinitions(projectId, 2)).ToList();

buildDefinitions.ShouldNotBeNull();
buildDefinitions.First().Id.ShouldNotBeNull();
buildDefinitions.First().Project.Id.ShouldNotBeNull();
}


[Fact]
[Trait("category", "integration")]
public async Task GetProjectRetentionSetting()
Expand Down
36 changes: 0 additions & 36 deletions VstsService.Tests/HttpRequestMessageExtensionsTests.cs

This file was deleted.

This file was deleted.

94 changes: 0 additions & 94 deletions VstsService.Tests/Processors/QueryBatchProcessorTests.cs

This file was deleted.

29 changes: 0 additions & 29 deletions VstsService.Tests/TaskGroup.cs

This file was deleted.

39 changes: 0 additions & 39 deletions VstsService.Tests/TestManagement.cs

This file was deleted.

26 changes: 0 additions & 26 deletions VstsService.Tests/Timeline.cs

This file was deleted.

2 changes: 1 addition & 1 deletion VstsService.Tests/VstsRestClientTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ public async Task RestRequestResultAsJsonObject()
[Fact]
public async Task NotFoundIsNull()
{
var result = await _vsts.GetAsync(Requests.Builds.Build(_config.Project, "2342423"));
var result = await _vsts.GetAsync(Requests.Builds.BuildDefinition(_config.Project, "2342423"));
result.ShouldBeNull();
}
}
Expand Down
36 changes: 0 additions & 36 deletions VstsService.Tests/Wiql.cs

This file was deleted.

Loading

0 comments on commit 5b130de

Please sign in to comment.