Lucene.Net
  1. Lucene.Net
  2. LUCENENET-435

Fix the test suite for Lucene.Net Core

    Details

      Description

      If wish to work on one of these, create a new sub-task from this one, assign it to yourself and submit the patch or commit it. make sure that if you create any new files to include the apache 2.0 license.

      • There needs to be a running list of things to do/not to do with testing. I don't know if this goes in a jira or do we keep a running list on the wiki or site for people to pick up and help with.
      • Tests need to run on mono and not Fail (there is a good deal of failing tests on mono, mostly due to the temp directory have the C:\ in the path).
      • Assert.Throw<ExceptionType>() needs to be used instead of Try/Catch Assert.Fail. **
      • File & Path combines to the temp directory need helper methods,
      • e,g, having this in a hundred places is bad new System.IO.FileInfo(System.IO.Path.Combine(Support.AppSettings.Get("tempDir", ""), "testIndex"));
      • We should still be testing deprecated methods, but we need to use #pragma warning disable/enable 0618 for testing those. otherwise compiler warnings are too numerous to be anywhere near helpful.
      • We should only be using deprecated methods in places where they are being explicitly tested, other tests that need that functionality in order to validate those tests should be re factored to use methods that are not deprecated.
      • Identify code that could be abstracted into test utility classes.
      • Infrastructure Validation tests need to be made, anything that seems like infrastructure. e.g. does the temp directory exist, does the folders that the tests use inside the temp directory exist, can we read/write to those folders. (if a ton of tests fail due to the file system, we should be able to point out that it was due to permissions or missing folders, files, etc).
      • Identify what classes need an interface, abstract class or inherited in order to create testing mocks. (once those classes are created, they should be documented in the wiki).
      • fix rethrows inside try/catches that log information then rethrows the exception. i.e. use throw; instead of throw ex;

      Note Assert.Throws needs to replace stuff like the following. We should also be checking the messages for exceptions and make sure they make sense and can help users fix isses if the exceptions are aimed at the library users.
      try

      { d = DateTools.StringToDate("97"); // no date Assert.Fail(); }

      catch (System.FormatException e)
      {
      /* expected exception */

        Activity

        michael herndon created issue -
        michael herndon made changes -
        Field Original Value New Value
        Description  * There needs to be a running list of things to do/not to do with testing. I don't know if this goes in a jira or do we keep a running list on the wiki or site for people to pick up and help with.
         * Tests need to run on mono and not Fail (there is a good deal of failing tests on mono, mostly due to the temp directory have the C:\ in the path).
         * Assert.Throw<ExceptionType>() needs to be used instead of Try/Catch Assert.Fail. **
         * File & Path combines to the temp directory need helper methods,
             * e,g, having this in a hundred places is bad new System.IO.FileInfo(System.IO.Path.Combine(Support.AppSettings.Get("tempDir", ""), "testIndex"));
         * We should still be testing deprecated methods, but we need to use #pragma warning disable/enable 0618 for testing those. otherwise compiler warnings are too numerous to be anywhere near helpful.
         * We should only be using deprecated methods in places where they are being explicitly tested, other tests that need that functionality in order to validate those tests should be re factored to use methods that are not deprecated.
         * Identify code that could be abstracted into test utility classes.
         * Infrastructure Validation tests need to be made, anything that seems like infrastructure. e.g. does the temp directory exist, does the folders that the tests use inside the temp directory exist, can we read/write to those folders. (if a ton of tests fail due to the file system, we should be able to point out that it was due to permissions or missing folders, files, etc).
         * Identify what classes need an interface, abstract class or inherited in order to create testing mocks. (once those classes are created, they should be documented in the wiki).
         


        ** Asset.Throws needs to replace stuff like the following. We should also be checking the messages for exceptions and make sure they make sense and can help users fix isses if the exceptions are aimed at the library users.
        try
        {
        d = DateTools.StringToDate("97"); // no date
        Assert.Fail();
        }
        catch (System.FormatException e)
        {
        /* expected exception */
        If wish to work on one of these, create a new sub-task from this one, assign it to yourself and submit the patch or commit it. make sure that if you create any new files to include the apache 2.0 license.

         * There needs to be a running list of things to do/not to do with testing. I don't know if this goes in a jira or do we keep a running list on the wiki or site for people to pick up and help with.
         * Tests need to run on mono and not Fail (there is a good deal of failing tests on mono, mostly due to the temp directory have the C:\ in the path).
         * Assert.Throw<ExceptionType>() needs to be used instead of Try/Catch Assert.Fail. **
         * File & Path combines to the temp directory need helper methods,
             * e,g, having this in a hundred places is bad new System.IO.FileInfo(System.IO.Path.Combine(Support.AppSettings.Get("tempDir", ""), "testIndex"));
         * We should still be testing deprecated methods, but we need to use #pragma warning disable/enable 0618 for testing those. otherwise compiler warnings are too numerous to be anywhere near helpful.
         * We should only be using deprecated methods in places where they are being explicitly tested, other tests that need that functionality in order to validate those tests should be re factored to use methods that are not deprecated.
         * Identify code that could be abstracted into test utility classes.
         * Infrastructure Validation tests need to be made, anything that seems like infrastructure. e.g. does the temp directory exist, does the folders that the tests use inside the temp directory exist, can we read/write to those folders. (if a ton of tests fail due to the file system, we should be able to point out that it was due to permissions or missing folders, files, etc).
         * Identify what classes need an interface, abstract class or inherited in order to create testing mocks. (once those classes are created, they should be documented in the wiki).
         


        Note Asset.Throws needs to replace stuff like the following. We should also be checking the messages for exceptions and make sure they make sense and can help users fix isses if the exceptions are aimed at the library users.
        try
        {
        d = DateTools.StringToDate("97"); // no date
        Assert.Fail();
        }
        catch (System.FormatException e)
        {
        /* expected exception */
        michael herndon made changes -
        Description If wish to work on one of these, create a new sub-task from this one, assign it to yourself and submit the patch or commit it. make sure that if you create any new files to include the apache 2.0 license.

         * There needs to be a running list of things to do/not to do with testing. I don't know if this goes in a jira or do we keep a running list on the wiki or site for people to pick up and help with.
         * Tests need to run on mono and not Fail (there is a good deal of failing tests on mono, mostly due to the temp directory have the C:\ in the path).
         * Assert.Throw<ExceptionType>() needs to be used instead of Try/Catch Assert.Fail. **
         * File & Path combines to the temp directory need helper methods,
             * e,g, having this in a hundred places is bad new System.IO.FileInfo(System.IO.Path.Combine(Support.AppSettings.Get("tempDir", ""), "testIndex"));
         * We should still be testing deprecated methods, but we need to use #pragma warning disable/enable 0618 for testing those. otherwise compiler warnings are too numerous to be anywhere near helpful.
         * We should only be using deprecated methods in places where they are being explicitly tested, other tests that need that functionality in order to validate those tests should be re factored to use methods that are not deprecated.
         * Identify code that could be abstracted into test utility classes.
         * Infrastructure Validation tests need to be made, anything that seems like infrastructure. e.g. does the temp directory exist, does the folders that the tests use inside the temp directory exist, can we read/write to those folders. (if a ton of tests fail due to the file system, we should be able to point out that it was due to permissions or missing folders, files, etc).
         * Identify what classes need an interface, abstract class or inherited in order to create testing mocks. (once those classes are created, they should be documented in the wiki).
         


        Note Asset.Throws needs to replace stuff like the following. We should also be checking the messages for exceptions and make sure they make sense and can help users fix isses if the exceptions are aimed at the library users.
        try
        {
        d = DateTools.StringToDate("97"); // no date
        Assert.Fail();
        }
        catch (System.FormatException e)
        {
        /* expected exception */
        If wish to work on one of these, create a new sub-task from this one, assign it to yourself and submit the patch or commit it. make sure that if you create any new files to include the apache 2.0 license.

         * There needs to be a running list of things to do/not to do with testing. I don't know if this goes in a jira or do we keep a running list on the wiki or site for people to pick up and help with.
         * Tests need to run on mono and not Fail (there is a good deal of failing tests on mono, mostly due to the temp directory have the C:\ in the path).
         * Assert.Throw<ExceptionType>() needs to be used instead of Try/Catch Assert.Fail. **
         * File & Path combines to the temp directory need helper methods,
             * e,g, having this in a hundred places is bad new System.IO.FileInfo(System.IO.Path.Combine(Support.AppSettings.Get("tempDir", ""), "testIndex"));
         * We should still be testing deprecated methods, but we need to use #pragma warning disable/enable 0618 for testing those. otherwise compiler warnings are too numerous to be anywhere near helpful.
         * We should only be using deprecated methods in places where they are being explicitly tested, other tests that need that functionality in order to validate those tests should be re factored to use methods that are not deprecated.
         * Identify code that could be abstracted into test utility classes.
         * Infrastructure Validation tests need to be made, anything that seems like infrastructure. e.g. does the temp directory exist, does the folders that the tests use inside the temp directory exist, can we read/write to those folders. (if a ton of tests fail due to the file system, we should be able to point out that it was due to permissions or missing folders, files, etc).
         * Identify what classes need an interface, abstract class or inherited in order to create testing mocks. (once those classes are created, they should be documented in the wiki).
         * fix rethrows inside try/catches that log information then rethrows the exception. i.e. use throw; instead of throw ex;


        Note Asset.Throws needs to replace stuff like the following. We should also be checking the messages for exceptions and make sure they make sense and can help users fix isses if the exceptions are aimed at the library users.
        try
        {
        d = DateTools.StringToDate("97"); // no date
        Assert.Fail();
        }
        catch (System.FormatException e)
        {
        /* expected exception */
        Christopher Currens made changes -
        Fix Version/s Lucene.Net 3.0.3 [ 12316215 ]
        Description If wish to work on one of these, create a new sub-task from this one, assign it to yourself and submit the patch or commit it. make sure that if you create any new files to include the apache 2.0 license.

         * There needs to be a running list of things to do/not to do with testing. I don't know if this goes in a jira or do we keep a running list on the wiki or site for people to pick up and help with.
         * Tests need to run on mono and not Fail (there is a good deal of failing tests on mono, mostly due to the temp directory have the C:\ in the path).
         * Assert.Throw<ExceptionType>() needs to be used instead of Try/Catch Assert.Fail. **
         * File & Path combines to the temp directory need helper methods,
             * e,g, having this in a hundred places is bad new System.IO.FileInfo(System.IO.Path.Combine(Support.AppSettings.Get("tempDir", ""), "testIndex"));
         * We should still be testing deprecated methods, but we need to use #pragma warning disable/enable 0618 for testing those. otherwise compiler warnings are too numerous to be anywhere near helpful.
         * We should only be using deprecated methods in places where they are being explicitly tested, other tests that need that functionality in order to validate those tests should be re factored to use methods that are not deprecated.
         * Identify code that could be abstracted into test utility classes.
         * Infrastructure Validation tests need to be made, anything that seems like infrastructure. e.g. does the temp directory exist, does the folders that the tests use inside the temp directory exist, can we read/write to those folders. (if a ton of tests fail due to the file system, we should be able to point out that it was due to permissions or missing folders, files, etc).
         * Identify what classes need an interface, abstract class or inherited in order to create testing mocks. (once those classes are created, they should be documented in the wiki).
         * fix rethrows inside try/catches that log information then rethrows the exception. i.e. use throw; instead of throw ex;


        Note Asset.Throws needs to replace stuff like the following. We should also be checking the messages for exceptions and make sure they make sense and can help users fix isses if the exceptions are aimed at the library users.
        try
        {
        d = DateTools.StringToDate("97"); // no date
        Assert.Fail();
        }
        catch (System.FormatException e)
        {
        /* expected exception */
        If wish to work on one of these, create a new sub-task from this one, assign it to yourself and submit the patch or commit it. make sure that if you create any new files to include the apache 2.0 license.

         * There needs to be a running list of things to do/not to do with testing. I don't know if this goes in a jira or do we keep a running list on the wiki or site for people to pick up and help with.
         * Tests need to run on mono and not Fail (there is a good deal of failing tests on mono, mostly due to the temp directory have the C:\ in the path).
         * Assert.Throw<ExceptionType>() needs to be used instead of Try/Catch Assert.Fail. **
         * File & Path combines to the temp directory need helper methods,
             * e,g, having this in a hundred places is bad new System.IO.FileInfo(System.IO.Path.Combine(Support.AppSettings.Get("tempDir", ""), "testIndex"));
         * We should still be testing deprecated methods, but we need to use #pragma warning disable/enable 0618 for testing those. otherwise compiler warnings are too numerous to be anywhere near helpful.
         * We should only be using deprecated methods in places where they are being explicitly tested, other tests that need that functionality in order to validate those tests should be re factored to use methods that are not deprecated.
         * Identify code that could be abstracted into test utility classes.
         * Infrastructure Validation tests need to be made, anything that seems like infrastructure. e.g. does the temp directory exist, does the folders that the tests use inside the temp directory exist, can we read/write to those folders. (if a ton of tests fail due to the file system, we should be able to point out that it was due to permissions or missing folders, files, etc).
         * Identify what classes need an interface, abstract class or inherited in order to create testing mocks. (once those classes are created, they should be documented in the wiki).
         * fix rethrows inside try/catches that log information then rethrows the exception. i.e. use throw; instead of throw ex;


        Note Assert.Throws needs to replace stuff like the following. We should also be checking the messages for exceptions and make sure they make sense and can help users fix isses if the exceptions are aimed at the library users.
        try
        {
        d = DateTools.StringToDate("97"); // no date
        Assert.Fail();
        }
        catch (System.FormatException e)
        {
        /* expected exception */
        Christopher Currens made changes -
        Fix Version/s Lucene.Net 3.5 [ 12320145 ]
        Fix Version/s Lucene.Net 3.0.3 [ 12316215 ]
        Affects Version/s Lucene.Net 3.0.3 [ 12316215 ]

          People

          • Assignee:
            michael herndon
            Reporter:
            michael herndon
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:

              Time Tracking

              Estimated:
              Original Estimate - 336h
              336h
              Remaining:
              Remaining Estimate - 336h
              336h
              Logged:
              Time Spent - Not Specified
              Not Specified

                Development