This repository was archived by the owner on Jun 21, 2023. It is now read-only.
File tree Expand file tree Collapse file tree 4 files changed +34
-17
lines changed
GitHub.App/ViewModels/GitHubPane
GitHub.Exports.Reactive/ViewModels/GitHubPane
test/GitHub.App.UnitTests/ViewModels/GitHubPane Expand file tree Collapse file tree 4 files changed +34
-17
lines changed Original file line number Diff line number Diff line change 55
66namespace GitHub . App . ViewModels . GitHubPane
77{
8- /// <summary>
9- /// The viewmodel for a single annotation item in a list
10- /// </summary>
8+ /// <inheritdoc cref="IPullRequestAnnotationItemViewModel"/>
119 public class PullRequestAnnotationItemViewModel : ViewModelBase , IPullRequestAnnotationItemViewModel
1210 {
1311 bool isExpanded ;
1412
13+ /// <summary>
14+ /// Initializes the <see cref="PullRequestAnnotationItemViewModel"/>.
15+ /// </summary>
16+ /// <param name="annotation">The check run annotation model.</param>
1517 public PullRequestAnnotationItemViewModel ( CheckRunAnnotationModel annotation )
1618 {
1719 this . Annotation = annotation ;
1820 }
1921
20- /// <summary>
21- /// Gets the annotation model.
22- /// </summary>
22+ /// <inheritdoc />
2323 public CheckRunAnnotationModel Annotation { get ; }
2424
25- /// <summary>
26- /// Gets a formatted descriptor of the line(s) the annotation is about.
27- /// </summary>
25+ /// <inheritdoc />
2826 public string LineDescription => $ "{ Annotation . StartLine } :{ Annotation . EndLine } ";
2927
30- /// <summary>
31- /// Gets or sets a flag to control the expanded state.
32- /// </summary>
28+ /// <inheritdoc />
3329 public bool IsExpanded
3430 {
3531 get { return isExpanded ; }
Original file line number Diff line number Diff line change 22
33namespace GitHub . ViewModels . GitHubPane
44{
5+ /// <summary>
6+ /// The viewmodel for a single annotation item in a list
7+ /// </summary>
58 public interface IPullRequestAnnotationItemViewModel
69 {
10+ /// <summary>
11+ /// Gets the annotation model.
12+ /// </summary>
713 CheckRunAnnotationModel Annotation { get ; }
8- bool IsExpanded { get ; set ; }
14+
15+ /// <summary>
16+ /// Gets a formatted descriptor of the line(s) the annotation is about.
17+ /// </summary>
918 string LineDescription { get ; }
19+
20+ /// <summary>
21+ /// Gets or sets a flag to control the expanded state.
22+ /// </summary>
23+ bool IsExpanded { get ; set ; }
1024 }
1125}
Original file line number Diff line number Diff line change @@ -23,10 +23,14 @@ public class CheckRunModel
2323 /// </summary>
2424 public DateTimeOffset ? CompletedAt { get ; set ; }
2525
26- /// <summary>The check run's annotations.</summary>
26+ /// <summary>
27+ /// The check run's annotations.
28+ /// </summary>
2729 public List < CheckRunAnnotationModel > Annotations { get ; set ; }
2830
29- /// <summary>The name of the check for this check run.</summary>
31+ /// <summary>
32+ /// The name of the check for this check run.
33+ /// </summary>
3034 public string Name { get ; set ; }
3135
3236 /// <summary>
@@ -39,6 +43,9 @@ public class CheckRunModel
3943 /// </summary>
4044 public string Summary { get ; set ; }
4145
46+ /// <summary>
47+ /// The database id of a Check Run.
48+ /// </summary>
4249 public int DatabaseId { get ; set ; }
4350 }
4451}
Original file line number Diff line number Diff line change @@ -57,7 +57,7 @@ public async Task ShouldCreateChangesTreeAsync()
5757 Assert . That ( readme . FileName , Is . EqualTo ( "readme.md" ) ) ;
5858 }
5959
60- [ Test , Ignore ( "I broke it" ) ]
60+ [ Test ]
6161 public async Task FileCommentCountShouldTrackSessionInlineCommentsAsync ( )
6262 {
6363 var outdatedThread = CreateThread ( - 1 ) ;
@@ -88,7 +88,7 @@ public async Task FileCommentCountShouldTrackSessionInlineCommentsAsync()
8888 RaisePropertyChanged ( file , nameof ( file . InlineCommentThreads ) ) ;
8989 Assert . That ( ( ( IPullRequestFileNode ) target . Items [ 0 ] ) . CommentCount , Is . EqualTo ( 2 ) ) ;
9090
91- file . Received ( 1 ) . PropertyChanged += Arg . Any < PropertyChangedEventHandler > ( ) ;
91+ file . Received ( 2 ) . PropertyChanged += Arg . Any < PropertyChangedEventHandler > ( ) ;
9292 }
9393
9494 static PullRequestFilesViewModel CreateTarget ( )
You can’t perform that action at this time.
0 commit comments