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

(#139) issue Number is long, not int #140

Merged
merged 1 commit into from
May 10, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/GitHubMilestoneCleaner.Tests/IssueGroupEngineTests.cs
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
using System.Collections.Immutable;
using System.Runtime.InteropServices.ComTypes;
using GitHubMilestoneCleaner.Engines;

Check warning on line 3 in src/GitHubMilestoneCleaner.Tests/IssueGroupEngineTests.cs

View workflow job for this annotation

GitHub Actions / build (windows-2022)

Namespace 'GitHubMilestoneCleaner.Engines' contains no declarations
using Octokit;
using Shouldly;

namespace GitHubMilestoneCleaner.Tests;

Check warning on line 7 in src/GitHubMilestoneCleaner.Tests/IssueGroupEngineTests.cs

View workflow job for this annotation

GitHub Actions / build (windows-2022)

Namespace body block expected

public class IssueGroupEngineTests
{
public class MockIssueWrapper(string title, int number) : IssueGroupEngine.IIssueWrapper

Check warning on line 11 in src/GitHubMilestoneCleaner.Tests/IssueGroupEngineTests.cs

View workflow job for this annotation

GitHub Actions / build (windows-2022)

Class cannot have primary constructor
{
public string Title { get; } = title;

Check warning on line 13 in src/GitHubMilestoneCleaner.Tests/IssueGroupEngineTests.cs

View workflow job for this annotation

GitHub Actions / build (windows-2022)

Cannot resolve symbol 'title'
public int Number { get; } = number;
public long Number { get; } = number;

Check warning on line 14 in src/GitHubMilestoneCleaner.Tests/IssueGroupEngineTests.cs

View workflow job for this annotation

GitHub Actions / build (windows-2022)

Cannot resolve symbol 'number'
public Issue BackingIssue { get; } = new();
}

Expand All @@ -26,11 +26,11 @@
// given
var sut = new IssueGroupEngine();
var issues = new[] { lhs, rhs }
.Select(x =>

Check warning on line 29 in src/GitHubMilestoneCleaner.Tests/IssueGroupEngineTests.cs

View workflow job for this annotation

GitHub Actions / build (windows-2022)

Cannot resolve symbol 'Select'
new MockIssueWrapper(x, 1));

Check warning on line 30 in src/GitHubMilestoneCleaner.Tests/IssueGroupEngineTests.cs

View workflow job for this annotation

GitHub Actions / build (windows-2022)

Constructor 'MockIssueWrapper' has 0 parameter(s) but is invoked with 2 argument(s)

// when
var f = sut.GroupIssues(issues).ToList();

Check warning on line 33 in src/GitHubMilestoneCleaner.Tests/IssueGroupEngineTests.cs

View workflow job for this annotation

GitHub Actions / build (windows-2022)

Cannot resolve symbol 'ToList'

// then
f.Count.ShouldBe(1);
Expand All @@ -45,7 +45,7 @@
// given
var sut = new IssueGroupEngine();
var issues = new[] { lhs, rhs }
.Select(x =>

Check warning on line 48 in src/GitHubMilestoneCleaner.Tests/IssueGroupEngineTests.cs

View workflow job for this annotation

GitHub Actions / build (windows-2022)

Cannot resolve symbol 'Select'
new MockIssueWrapper(x, 1));

// when
Expand Down
2 changes: 1 addition & 1 deletion src/GitHubMilestoneCleaner/Commands/AutoCleanupCommand.cs
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ public IssueWrapper(Issue issue)
}

public string Title => BackingIssue.Title;
public int Number => BackingIssue.Number;
public long Number => BackingIssue.Number;
public Issue BackingIssue { get; }
}
}
2 changes: 1 addition & 1 deletion src/GitHubMilestoneCleaner/Engines/IssueGroupEngine.cs
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ public record IssueGroup
public interface IIssueWrapper
{
string Title { get; }
int Number { get; }
long Number { get; }
Issue BackingIssue { get; }
}
}
Loading