Skip to content

Commit

Permalink
Merge pull request #2184 from andy840119/rename-issue-template
Browse files Browse the repository at this point in the history
Rename issue template.
  • Loading branch information
andy840119 authored Mar 10, 2024
2 parents e3fb767 + 7b1163d commit 11fd78b
Show file tree
Hide file tree
Showing 22 changed files with 200 additions and 200 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -25,13 +25,13 @@ public void TestCheck(string language)
}

[TestCase(null)]
public void TestCheckNotFillLanguage(string? language)
public void TestCheckNotFill(string? language)
{
var lyric = new Lyric
{
Language = language != null ? new CultureInfo(language) : null,
};

AssertNotOk<LyricIssue, IssueTemplateLyricNotFillLanguage>(lyric);
AssertNotOk<LyricIssue, IssueTemplateNotFill>(lyric);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ public void TestCheckSelfReference()
lyric.ReferenceLyricId = lyric.ID;
lyric.ReferenceLyric = lyric;

AssertNotOk<LyricIssue, IssueTemplateLyricSelfReference>(lyric);
AssertNotOk<LyricIssue, IssueTemplateSelfReference>(lyric);
}

[Test]
Expand All @@ -52,7 +52,7 @@ public void TestCheckInvalidReferenceLyric()
ReferenceLyricConfig = new ReferenceLyricConfig(),
};

AssertNotOk<LyricIssue, IssueTemplateLyricInvalidReferenceLyric>(lyric);
AssertNotOk<LyricIssue, IssueTemplateInvalidReferenceLyric>(lyric);
}

[Test]
Expand All @@ -65,18 +65,18 @@ public void TestCheckNullReferenceLyricConfig()
ReferenceLyric = referencedLyric,
};

AssertNotOk<LyricIssue, IssueTemplateLyricNullReferenceLyricConfig>(new HitObject[] { referencedLyric, lyric });
AssertNotOk<LyricIssue, IssueTemplateNullReferenceLyricConfig>(new HitObject[] { referencedLyric, lyric });
}

[Test]
public void TestCheckHasReferenceLyricConfigIfNoReferenceLyric()
public void TestCheckHasReferenceLyricConfigWhenNoReferenceLyric()
{
var lyric = new Lyric
{
ReferenceLyric = null,
ReferenceLyricConfig = new ReferenceLyricConfig(),
};

AssertNotOk<LyricIssue, IssueTemplateLyricHasReferenceLyricConfigIfNoReferenceLyric>(lyric);
AssertNotOk<LyricIssue, IssueTemplateHasReferenceLyricConfigWhenNoReferenceLyric>(lyric);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -27,41 +27,41 @@ public void TestCheck(string text, string[] rubies)

[TestCase("カラオケ", new[] { "[-1]:か" })]
[TestCase("カラオケ", new[] { "[4]:け" })]
public void TestCheckRubyOutOfRange(string text, string[] rubies)
public void TestCheckOutOfRange(string text, string[] rubies)
{
var lyric = new Lyric
{
Text = text,
RubyTags = TestCaseTagHelper.ParseRubyTags(rubies),
};

AssertNotOk<LyricRubyTagIssue, IssueTemplateLyricRubyOutOfRange>(lyric);
AssertNotOk<LyricRubyTagIssue, IssueTemplateOutOfRange>(lyric);
}

[TestCase("カラオケ", new[] { "[0]:か", "[0]:ら" })]
[TestCase("カラオケ", new[] { "[0,3]:か", "[1,2]:ら" })]
public void TestCheckRubyOverlapping(string text, string[] rubies)
public void TestCheckOverlapping(string text, string[] rubies)
{
var lyric = new Lyric
{
Text = text,
RubyTags = TestCaseTagHelper.ParseRubyTags(rubies),
};

AssertNotOk<LyricRubyTagIssue, IssueTemplateLyricRubyOverlapping>(lyric);
AssertNotOk<LyricRubyTagIssue, IssueTemplateOverlapping>(lyric);
}

[TestCase("カラオケ", new[] { "[0,3]:" })]
[TestCase("カラオケ", new[] { "[0,3]: " })]
[TestCase("カラオケ", new[] { "[0,3]: " })]
public void TestCheckRubyEmptyText(string text, string[] rubies)
public void TestCheckEmptyText(string text, string[] rubies)
{
var lyric = new Lyric
{
Text = text,
RubyTags = TestCaseTagHelper.ParseRubyTags(rubies),
};

AssertNotOk<LyricRubyTagIssue, IssueTemplateLyricRubyEmptyText>(lyric);
AssertNotOk<LyricRubyTagIssue, IssueTemplateEmptyText>(lyric);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,6 @@ public void TestCheckNoSinger(int[] singers)
SingerIds = TestCaseElementIdHelper.CreateElementIdsByNumbers(singers),
};

AssertNotOk<LyricIssue, IssueTemplateLyricNoSinger>(lyric);
AssertNotOk<LyricIssue, IssueTemplateNoSinger>(lyric);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -29,13 +29,13 @@ public void TestCheck(string text)
[TestCase(" ")] // but should not be empty or white space.
[TestCase("")]
[TestCase(null)]
public void TestCheckNoText(string text)
public void TestCheckEmptyText(string text)
{
var lyric = new Lyric
{
Text = text,
};

AssertNotOk<LyricIssue, IssueTemplateLyricNoText>(lyric);
AssertNotOk<LyricIssue, IssueTemplateEmptyText>(lyric);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -28,39 +28,39 @@ public void TestCheck(string text, string[] timeTags)
}

[TestCase("カラオケ", new string[] { })]
public void TestCheckMissingNoTimeTag(string text, string[] timeTags)
public void TestCheckEmpty(string text, string[] timeTags)
{
var lyric = new Lyric
{
Text = text,
TimeTags = TestCaseTagHelper.ParseTimeTags(timeTags),
};

AssertNotOk<LyricIssue, IssueTemplateLyricEmptyTimeTag>(lyric);
AssertNotOk<LyricIssue, IssueTemplateEmpty>(lyric);
}

[TestCase("カラオケ", new[] { "[3,end]:5000" })]
public void TestCheckMissingFirstTimeTag(string text, string[] timeTags)
public void TestCheckMissingStart(string text, string[] timeTags)
{
var lyric = new Lyric
{
Text = text,
TimeTags = TestCaseTagHelper.ParseTimeTags(timeTags),
};

AssertNotOk<LyricIssue, IssueTemplateLyricMissingFirstTimeTag>(lyric);
AssertNotOk<LyricIssue, IssueTemplateMissingStart>(lyric);
}

[TestCase("カラオケ", new[] { "[0,start]:5000" })]
public void TestCheckMissingLastTimeTag(string text, string[] timeTags)
public void TestCheckMissingEnd(string text, string[] timeTags)
{
var lyric = new Lyric
{
Text = text,
TimeTags = TestCaseTagHelper.ParseTimeTags(timeTags),
};

AssertNotOk<LyricIssue, IssueTemplateLyricMissingLastTimeTag>(lyric);
AssertNotOk<LyricIssue, IssueTemplateMissingEnd>(lyric);
}

[TestCase("カラオケ", new[] { "[-1,start]:0", "[0,start]:1000", "[3,end]:1000" })] // out-of range start time-tag time.
Expand All @@ -73,7 +73,7 @@ public void TestCheckOutOfRange(string text, string[] timeTags)
TimeTags = TestCaseTagHelper.ParseTimeTags(timeTags),
};

AssertNotOk<LyricTimeTagIssue, IssueTemplateLyricTimeTagOutOfRange>(lyric);
AssertNotOk<LyricTimeTagIssue, IssueTemplateOutOfRange>(lyric);
}

[TestCase("カラオケ", new[] { "[0,start]:5000", "[3,end]:1000" })]
Expand All @@ -85,7 +85,7 @@ public void TestCheckOverlapping(string text, string[] timeTags)
TimeTags = TestCaseTagHelper.ParseTimeTags(timeTags),
};

AssertNotOk<LyricTimeTagIssue, IssueTemplateLyricTimeTagOverlapping>(lyric);
AssertNotOk<LyricTimeTagIssue, IssueTemplateOverlapping>(lyric);
}

[TestCase("カラオケ", new[] { "[0,start]", "[3,end]:1000" })] // empty start time-tag time.
Expand All @@ -99,13 +99,13 @@ public void TestCheckEmptyTime(string text, string[] timeTags)
TimeTags = TestCaseTagHelper.ParseTimeTags(timeTags),
};

AssertNotOk<LyricTimeTagIssue, IssueTemplateLyricTimeTagEmptyTime>(lyric);
AssertNotOk<LyricTimeTagIssue, IssueTemplateEmptyTime>(lyric);
}

[TestCase("カラオケ", "")] // should not be empty.
[TestCase("カラオケ", " ")] // should not be white-space only.
[TestCase("カラオケ", "卡拉OK")] // should be within latin.
public void TestCheckTimeTagRomajiInvalidText(string text, string romanisedSyllable)
public void TestCheckInvalidRomanisedSyllable(string text, string romanisedSyllable)
{
var lyric = new Lyric
{
Expand All @@ -124,11 +124,11 @@ public void TestCheckTimeTagRomajiInvalidText(string text, string romanisedSylla
},
};

AssertNotOk<LyricTimeTagIssue, IssueTemplateLyricTimeTagRomajiInvalidText>(lyric);
AssertNotOk<LyricTimeTagIssue, IssueTemplateInvalidRomanisedSyllable>(lyric);
}

[TestCase("カラオケ", null)] // should not be white-space only.
public void TestCheckRomajiEmptyTextIfFirst(string text, string romanisedSyllable)
public void TestCheckShouldFillRomanisedSyllable(string text, string romanisedSyllable)
{
var lyric = new Lyric
{
Expand All @@ -148,13 +148,13 @@ public void TestCheckRomajiEmptyTextIfFirst(string text, string romanisedSyllabl
},
};

AssertNotOk<LyricTimeTagIssue, IssueTemplateLyricTimeTagRomajiInvalidTextIfFirst>(lyric);
AssertNotOk<LyricTimeTagIssue, IssueTemplateShouldFillRomanisedSyllable>(lyric);
}

[TestCase("カラオケ", "")] // should not have empty text if end.
[TestCase("カラオケ", " ")] // should not have empty text if end.
[TestCase("カラオケ", "123")] // should not have empty text if end.
public void TestRomajiNotHaveEmptyTextIfEnd(string text, string romanisedSyllable)
public void TestCheckShouldNotFillRomanisedSyllable(string text, string romanisedSyllable)
{
var lyric = new Lyric
{
Expand All @@ -173,11 +173,11 @@ public void TestRomajiNotHaveEmptyTextIfEnd(string text, string romanisedSyllabl
},
};

AssertNotOk<LyricTimeTagIssue, IssueTemplateLyricTimeTagRomajiNotHaveEmptyTextIfEnd>(lyric);
AssertNotOk<LyricTimeTagIssue, IssueTemplateShouldNotFillRomanisedSyllable>(lyric);
}

[Test]
public void TestRomajiNotFistRomajiTextIfEnd()
public void TestCheckShouldNotMarkFirstSyllable()
{
var lyric = new Lyric
{
Expand All @@ -196,6 +196,6 @@ public void TestRomajiNotFistRomajiTextIfEnd()
},
};

AssertNotOk<LyricTimeTagIssue, IssueTemplateLyricTimeTagRomajiNotFistRomajiTextIfEnd>(lyric);
AssertNotOk<LyricTimeTagIssue, IssueTemplateShouldNotMarkFirstSyllable>(lyric);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ public void TestCheckTimeOverlapping(string lyricText, string[] timeTags)
var lyric = TestCaseTagHelper.ParseLyric(lyricText);
lyric.TimeTags = TestCaseTagHelper.ParseTimeTags(timeTags);

AssertNotOk<LyricIssue, IssueTemplateLyricTimeOverlapping>(lyric);
AssertNotOk<LyricIssue, IssueTemplateTimeOverlapping>(lyric);
}

[TestCase("[2000,3000]:カラオケ", new[] { "[0,start]:1000", "[3,end]:3000" })]
Expand All @@ -36,7 +36,7 @@ public void TestCheckStartTimeInvalid(string lyricText, string[] timeTags)
var lyric = TestCaseTagHelper.ParseLyric(lyricText);
lyric.TimeTags = TestCaseTagHelper.ParseTimeTags(timeTags);

AssertNotOk<LyricIssue, IssueTemplateLyricStartTimeInvalid>(lyric);
AssertNotOk<LyricIssue, IssueTemplateStartTimeInvalid>(lyric);
}

[TestCase("[1000,2000]:カラオケ", new[] { "[0,start]:1000", "[3,end]:3000" })]
Expand All @@ -45,6 +45,6 @@ public void TestCheckEndTimeInvalid(string lyricText, string[] timeTags)
var lyric = TestCaseTagHelper.ParseLyric(lyricText);
lyric.TimeTags = TestCaseTagHelper.ParseTimeTags(timeTags);

AssertNotOk<LyricIssue, IssueTemplateLyricEndTimeInvalid>(lyric);
AssertNotOk<LyricIssue, IssueTemplateEndTimeInvalid>(lyric);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ public void TestCheck(string text)
[TestCase("")]
[TestCase(" ")] // but should not be empty or white space.
[TestCase(" ")] // but should not be empty or white space.
public void TestCheckTranslationNoText(string text)
public void TestCheckEmptyText(string text)
{
var lyric = new Lyric
{
Expand All @@ -43,6 +43,6 @@ public void TestCheckTranslationNoText(string text)
},
};

AssertNotOk<LyricIssue, IssueTemplateLyricTranslationNoText>(lyric);
AssertNotOk<LyricIssue, IssueTemplateEmptyText>(lyric);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ public void TestCheckNullReferenceLyric()
ReferenceLyric = null, // reference should not be null.
};

AssertNotOk<NoteIssue, IssueTemplateNoteNullReferenceLyric>(note);
AssertNotOk<NoteIssue, IssueTemplateNullReferenceLyric>(note);
}

[Test]
Expand All @@ -63,7 +63,7 @@ public void TestCheckInvalidReferenceLyric()
ReferenceTimeTagIndex = 0,
};

AssertNotOk<NoteIssue, IssueTemplateNoteInvalidReferenceLyric>(note);
AssertNotOk<NoteIssue, IssueTemplateInvalidReferenceLyric>(note);
}

[TestCase(2, new[] { "[0,start]:1000", "[3,end]:5000" })] // will find the time-tag at index 2 and 3.
Expand All @@ -85,7 +85,7 @@ public void TestCheckMissingReferenceTimeTag(int referenceTimeTagIndex, string[]
ReferenceTimeTagIndex = referenceTimeTagIndex,
};

AssertNotOk<NoteIssue, IssueTemplateNoteMissingReferenceTimeTag>(new HitObject[] { referencedLyric, note });
AssertNotOk<NoteIssue, IssueTemplateMissingReferenceTimeTag>(new HitObject[] { referencedLyric, note });
}

[TestCase(-1, new[] { "[0,start]:1000", "[3,end]:5000" })]
Expand All @@ -104,7 +104,7 @@ public void TestCheckMissingStartReferenceTimeTag(int referenceTimeTagIndex, str
ReferenceTimeTagIndex = referenceTimeTagIndex,
};

AssertNotOk<NoteIssue, IssueTemplateNoteMissingStartReferenceTimeTag>(new HitObject[] { referencedLyric, note });
AssertNotOk<NoteIssue, IssueTemplateMissingStartReferenceTimeTag>(new HitObject[] { referencedLyric, note });
}

[TestCase(0, new[] { "[0,start]", "[3,end]:5000" })]
Expand All @@ -124,7 +124,7 @@ public void TestCheckStartReferenceTimeTagMissingTime(int referenceTimeTagIndex,
ReferenceTimeTagIndex = referenceTimeTagIndex,
};

AssertNotOk<NoteIssue, IssueTemplateNoteStartReferenceTimeTagMissingTime>(new HitObject[] { referencedLyric, note });
AssertNotOk<NoteIssue, IssueTemplateStartReferenceTimeTagMissingTime>(new HitObject[] { referencedLyric, note });
}

[TestCase(1, new[] { "[0,start]:1000", "[3,end]:5000" })]
Expand All @@ -143,7 +143,7 @@ public void TestCheckMissingEndReferenceTimeTag(int referenceTimeTagIndex, strin
ReferenceTimeTagIndex = referenceTimeTagIndex,
};

AssertNotOk<NoteIssue, IssueTemplateNoteMissingEndReferenceTimeTag>(new HitObject[] { referencedLyric, note });
AssertNotOk<NoteIssue, IssueTemplateMissingEndReferenceTimeTag>(new HitObject[] { referencedLyric, note });
}

[TestCase(0, new[] { "[0,start]:1000", "[3,end]" })]
Expand All @@ -163,6 +163,6 @@ public void TestCheckEndReferenceTimeTagMissingTime(int referenceTimeTagIndex, s
ReferenceTimeTagIndex = referenceTimeTagIndex,
};

AssertNotOk<NoteIssue, IssueTemplateNoteEndReferenceTimeTagMissingTime>(new HitObject[] { referencedLyric, note });
AssertNotOk<NoteIssue, IssueTemplateEndReferenceTimeTagMissingTime>(new HitObject[] { referencedLyric, note });
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -28,27 +28,27 @@ public void TestCheck()
[TestCase("")]
[TestCase(" ")] // but should not be empty or white space.
[TestCase(" ")] // but should not be empty or white space.
public void TestCheckNoText(string text)
public void TestCheckEmptyText(string text)
{
var note = new Note
{
Text = text,
};

AssertNotOk<NoteIssue, IssueTemplateNoteNoText>(note);
AssertNotOk<NoteIssue, IssueTemplateEmptyText>(note);
}

[TestCase("")]
[TestCase(" ")] // but should not be empty or white space.
[TestCase(" ")] // but should not be empty or white space.
public void TestCheckNoRubyText(string? rubyText)
public void TestCheckEmptyRubyText(string? rubyText)
{
var note = new Note
{
Text = "karaoke",
RubyText = rubyText,
};

AssertNotOk<NoteIssue, IssueTemplateNoteNoRubyText>(note);
AssertNotOk<NoteIssue, IssueTemplateEmptyRubyText>(note);
}
}
Loading

0 comments on commit 11fd78b

Please sign in to comment.