How do you know if the xml-commentary method has?



  • I'm testing the Unit for my programme and I'd like to know if an audit of the existence of a comment could be added. /// <summary> the method?



    1. When the swagger service is connected, indicate the way to an automatically-generated file with project documentation.
    2. With help XDocument xdoc = XDocument.Load(SwaggerFile); Get a file with swagger comments.
    3. It may be diluted as follows:
                       .Element("members")
                       .Elements("member")
                       .Where(element => element.Attribute("name").Value.EndsWith("Controller"))
                       .Select(element => new ControlClassWithDescription
                       {
                           Name = element.Attribute("name").Value,
                           SummaryExist = element.Element("summary") != null,
                       });
    

    Preconditioning class ControlClassWithDescription

    1. See if all the counter-eller files are on the list.


Suggested Topics

  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2