void ribi::c2h::QtCodeToHtmlMainDialog::Test() noexcept
{
  {
    static bool is_tested{false};
    if (is_tested) return;
    is_tested = true;
  }
  {
    ribi::fileio::FileIo();
    Dialog();
  }
  const TestTimer test_timer(__func__,__FILE__,1.0);
  //IsRegularFile
  {
    assert(!ribi::fileio::FileIo().IsRegularFile("../ToolCodeToHtml"));
  }
  {
    QtCodeToHtmlMainDialog d;
    for (int index = 0; index != 2; ++index)
    {
      d.ui->tab_source->setCurrentIndex(index);
      for (const std::string& s:
        {
          "/home/richel/ProjectRichelBilderbeek/Tools/ToolTestAbout",
          "D:/Projects/Tools/ToolTestAbout",
          "D:\\Projects\\Tools\\ToolTestAbout",
          "D:/Projects/Test/ToolTestAbout",
          "D:\\Projects\\Test\\ToolTestAbout",
          //"../../Tools/ToolCodeToHtml",
          "..\\..\\Tools\\ToolTestAbout",
          "../../Tools/ToolTestAbout",
          "..\\..\\Tools\\ToolTestAbout",
          "/home/richel/ProjectRichelBilderbeek/Test/ToolTestAbout"
        }
      )
      {
        d.ui->edit_source->setText(s.c_str());
        if (d.ui->button_convert->isEnabled())
        {
          d.on_button_convert_clicked();
        }
      }
    }
  }
}
void ribi::c2h::QtCodeToHtmlMainDialog::Test() noexcept
{
  {
    static bool is_tested = false;
    if (is_tested) return;
    is_tested = true;
  }
  TRACE("Starting QtCodeToHtmlMainDialog::Test");
  //IsRegularFile
  {
    assert(!ribi::fileio::IsRegularFile("../ToolCodeToHtml"));
  }
  {
    QtCodeToHtmlMainDialog d;
    for (int index = 0; index != 2; ++index)
    {
      d.ui->tab_source->setCurrentIndex(index);
      for (const std::string& s:
        {
          "/home/richel/ProjectRichelBilderbeek/Tools/ToolCodeToHtml",
          "D:/Projects/Tools/ToolCodeToHtml",
          "D:\\Projects\\Tools\\ToolCodeToHtml",
          "D:/Projects/Test/ToolOpenFoamExample1",
          "D:\\Projects\\Test\\ToolOpenFoamExample1",
          "../../Tools/ToolCodeToHtml",
          "..\\..\\Tools\\ToolCodeToHtml",
          "../../Test/ToolOpenFoamExample1",
          "..\\..\\Test\\ToolOpenFoamExample1",
          "/home/richel/ProjectRichelBilderbeek/Test/ToolOpenFoamExample1"
        }
      )
      {
        d.ui->edit_source->setText(s.c_str());
        if (d.ui->button_convert->isEnabled())
        {
          d.on_button_convert_clicked();
        }
      }
    }
  }
  TRACE("Finished QtCodeToHtmlMainDialog::Test successfully");
}