Skip to content

Commit

Permalink
BUG: Lucene.Net.Tests.Queries.Function.TestFieldScoreQuery: Added mis…
Browse files Browse the repository at this point in the history
…sing [Test] attributes (apache#259)
  • Loading branch information
NightOwl888 committed Feb 22, 2021
1 parent 78f07cf commit 10870c9
Showing 1 changed file with 8 additions and 19 deletions.
27 changes: 8 additions & 19 deletions src/Lucene.Net.Tests.Queries/Function/TestFieldScoreQuery.cs
Original file line number Diff line number Diff line change
Expand Up @@ -115,42 +115,34 @@ private void DoTestRank(ValueSource valueSource)

/// <summary>
/// Test that FieldScoreQuery of Type.BYTE returns the expected scores. </summary>
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes:
//ORIGINAL LINE: @Test public void testExactScoreByte() throws Exception
//JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in .NET:
public virtual void testExactScoreByte()
[Test]
public virtual void TestExactScoreByte()
{
// INT field values are small enough to be parsed as byte
doTestExactScore(BYTE_VALUESOURCE);
}

/// <summary>
/// Test that FieldScoreQuery of Type.SHORT returns the expected scores. </summary>
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes:
//ORIGINAL LINE: @Test public void testExactScoreShort() throws Exception
//JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in .NET:
public virtual void testExactScoreShort()
[Test]
public virtual void TestExactScoreShort()
{
// INT field values are small enough to be parsed as short
doTestExactScore(SHORT_VALUESOURCE);
}

/// <summary>
/// Test that FieldScoreQuery of Type.INT returns the expected scores. </summary>
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes:
//ORIGINAL LINE: @Test public void testExactScoreInt() throws Exception
//JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in .NET:
public virtual void testExactScoreInt()
[Test]
public virtual void TestExactScoreInt()
{
doTestExactScore(INT_VALUESOURCE);
}

/// <summary>
/// Test that FieldScoreQuery of Type.FLOAT returns the expected scores. </summary>
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes:
//ORIGINAL LINE: @Test public void testExactScoreFloat() throws Exception
//JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in .NET:
public virtual void testExactScoreFloat()
[Test]
public virtual void TestExactScoreFloat()
{
// INT field can be parsed as float
doTestExactScore(INT_AS_FLOAT_VALUESOURCE);
Expand All @@ -159,8 +151,6 @@ public virtual void testExactScoreFloat()
}

// Test that FieldScoreQuery returns docs with expected score.
//JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in .NET:
//ORIGINAL LINE: private void doTestExactScore(ValueSource valueSource) throws Exception
private void doTestExactScore(ValueSource valueSource)
{
FunctionQuery functionQuery = new FunctionQuery(valueSource);
Expand All @@ -179,6 +169,5 @@ private void doTestExactScore(ValueSource valueSource)
}
r.Dispose();
}

}
}

0 comments on commit 10870c9

Please sign in to comment.