Skip to content

Commit 7094713

Browse files
committed
a bit more
1 parent 88408b9 commit 7094713

File tree

6 files changed

+2
-57
lines changed

6 files changed

+2
-57
lines changed

NGitLab.Mock/Clients/PipelineClient.cs

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -156,12 +156,6 @@ public Models.Job[] GetJobs(long pipelineId)
156156
}
157157
}
158158

159-
[Obsolete("Use JobClient.GetJobs() instead")]
160-
public IEnumerable<Models.Job> GetJobsInProject(JobScope scope)
161-
{
162-
throw new NotImplementedException();
163-
}
164-
165159
public IEnumerable<PipelineBasic> Search(PipelineQuery query)
166160
{
167161
using (Context.BeginOperationScope())

NGitLab/IPipelineClient.cs

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
1-
using System;
2-
using System.Collections.Generic;
1+
using System.Collections.Generic;
32
using System.Threading;
43
using System.Threading.Tasks;
54
using NGitLab.Models;
@@ -29,13 +28,6 @@ public interface IPipelineClient
2928

3029
GitLabCollectionResponse<Job> GetAllJobsAsync();
3130

32-
/// <summary>
33-
/// Get jobs in a project meeting the scope
34-
/// </summary>
35-
/// <param name="scope"></param>
36-
[Obsolete("Use JobClient.GetJobs() instead")]
37-
IEnumerable<Job> GetJobsInProject(JobScope scope);
38-
3931
/// <summary>
4032
/// Returns the jobs of a pipeline.
4133
/// </summary>

NGitLab/Impl/PipelineClient.cs

Lines changed: 0 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -31,19 +31,6 @@ public GitLabCollectionResponse<Job> GetAllJobsAsync()
3131
return _api.Get().GetAllAsync<Job>($"{_projectPath}/jobs");
3232
}
3333

34-
[Obsolete("Use JobClient.GetJobs() instead")]
35-
public IEnumerable<Job> GetJobsInProject(JobScope scope)
36-
{
37-
var url = $"{_projectPath}/jobs";
38-
39-
if (scope != JobScope.All)
40-
{
41-
url = Utils.AddParameter(url, "scope", scope.ToString().ToLowerInvariant());
42-
}
43-
44-
return _api.Get().GetAll<Job>(url);
45-
}
46-
4734
public Pipeline this[long id] => _api.Get().To<Pipeline>($"{_pipelinesPath}/{id.ToStringInvariant()}");
4835

4936
public Task<Pipeline> GetByIdAsync(long id, CancellationToken cancellationToken = default)

NGitLab/Models/CompareQuery.cs

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,4 @@
1-
using System.Text.Json.Serialization;
2-
3-
namespace NGitLab.Models;
1+
namespace NGitLab.Models;
42

53
/// <summary>
64
/// Query details for comparison of branches/tags/commit hashes

NGitLab/Models/JobScope.cs

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -2,20 +2,6 @@
22

33
namespace NGitLab.Models;
44

5-
[Obsolete("Use JobScopeMask instead")]
6-
public enum JobScope
7-
{
8-
All,
9-
Created,
10-
Pending,
11-
Running,
12-
Failed,
13-
Success,
14-
Canceled,
15-
Skipped,
16-
Manual,
17-
}
18-
195
[Flags]
206
public enum JobScopeMask
217
{

NGitLab/PublicAPI.Unshipped.txt

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -804,7 +804,6 @@ NGitLab.Impl.PipelineClient.GetByIdAsync(long id, System.Threading.CancellationT
804804
NGitLab.Impl.PipelineClient.GetJobs(long pipelineId) -> NGitLab.Models.Job[]
805805
NGitLab.Impl.PipelineClient.GetJobs(NGitLab.Models.PipelineJobQuery query) -> System.Collections.Generic.IEnumerable<NGitLab.Models.Job>
806806
NGitLab.Impl.PipelineClient.GetJobsAsync(NGitLab.Models.PipelineJobQuery query) -> NGitLab.GitLabCollectionResponse<NGitLab.Models.Job>
807-
NGitLab.Impl.PipelineClient.GetJobsInProject(NGitLab.Models.JobScope scope) -> System.Collections.Generic.IEnumerable<NGitLab.Models.Job>
808807
NGitLab.Impl.PipelineClient.GetTestReports(long pipelineId) -> NGitLab.Models.TestReport
809808
NGitLab.Impl.PipelineClient.GetTestReportsSummary(long pipelineId) -> NGitLab.Models.TestReportSummary
810809
NGitLab.Impl.PipelineClient.GetVariables(long pipelineId) -> System.Collections.Generic.IEnumerable<NGitLab.Models.PipelineVariable>
@@ -1002,7 +1001,6 @@ NGitLab.IPipelineClient.GetByIdAsync(long id, System.Threading.CancellationToken
10021001
NGitLab.IPipelineClient.GetJobs(long pipelineId) -> NGitLab.Models.Job[]
10031002
NGitLab.IPipelineClient.GetJobs(NGitLab.Models.PipelineJobQuery query) -> System.Collections.Generic.IEnumerable<NGitLab.Models.Job>
10041003
NGitLab.IPipelineClient.GetJobsAsync(NGitLab.Models.PipelineJobQuery query) -> NGitLab.GitLabCollectionResponse<NGitLab.Models.Job>
1005-
NGitLab.IPipelineClient.GetJobsInProject(NGitLab.Models.JobScope scope) -> System.Collections.Generic.IEnumerable<NGitLab.Models.Job>
10061004
NGitLab.IPipelineClient.GetTestReports(long pipelineId) -> NGitLab.Models.TestReport
10071005
NGitLab.IPipelineClient.GetTestReportsSummary(long pipelineId) -> NGitLab.Models.TestReportSummary
10081006
NGitLab.IPipelineClient.GetVariables(long pipelineId) -> System.Collections.Generic.IEnumerable<NGitLab.Models.PipelineVariable>
@@ -2572,16 +2570,6 @@ NGitLab.Models.JobQuery.PerPage.get -> int?
25722570
NGitLab.Models.JobQuery.PerPage.set -> void
25732571
NGitLab.Models.JobQuery.Scope.get -> NGitLab.Models.JobScopeMask
25742572
NGitLab.Models.JobQuery.Scope.set -> void
2575-
NGitLab.Models.JobScope
2576-
NGitLab.Models.JobScope.All = 0 -> NGitLab.Models.JobScope
2577-
NGitLab.Models.JobScope.Canceled = 6 -> NGitLab.Models.JobScope
2578-
NGitLab.Models.JobScope.Created = 1 -> NGitLab.Models.JobScope
2579-
NGitLab.Models.JobScope.Failed = 4 -> NGitLab.Models.JobScope
2580-
NGitLab.Models.JobScope.Manual = 8 -> NGitLab.Models.JobScope
2581-
NGitLab.Models.JobScope.Pending = 2 -> NGitLab.Models.JobScope
2582-
NGitLab.Models.JobScope.Running = 3 -> NGitLab.Models.JobScope
2583-
NGitLab.Models.JobScope.Skipped = 7 -> NGitLab.Models.JobScope
2584-
NGitLab.Models.JobScope.Success = 5 -> NGitLab.Models.JobScope
25852573
NGitLab.Models.JobScopeMask
25862574
NGitLab.Models.JobScopeMask.All = NGitLab.Models.JobScopeMask.Created | NGitLab.Models.JobScopeMask.Pending | NGitLab.Models.JobScopeMask.Running | NGitLab.Models.JobScopeMask.Failed | NGitLab.Models.JobScopeMask.Success | NGitLab.Models.JobScopeMask.Canceled | NGitLab.Models.JobScopeMask.Skipped | NGitLab.Models.JobScopeMask.Manual -> NGitLab.Models.JobScopeMask
25872575
NGitLab.Models.JobScopeMask.Canceled = 32 -> NGitLab.Models.JobScopeMask

0 commit comments

Comments
 (0)