<commit_before>#include <libmesh/elem.h>

#include <libmesh/cell_hex20.h>
#include <libmesh/cell_hex27.h>
#include <libmesh/cell_hex8.h>
#include <libmesh/cell_inf_hex16.h>
#include <libmesh/cell_inf_hex18.h>
#include <libmesh/cell_inf_hex8.h>
#include <libmesh/cell_inf_prism12.h>
#include <libmesh/cell_inf_prism6.h>
#include <libmesh/cell_prism15.h>
#include <libmesh/cell_prism18.h>
#include <libmesh/cell_prism6.h>
#include <libmesh/cell_pyramid13.h>
#include <libmesh/cell_pyramid14.h>
#include <libmesh/cell_pyramid5.h>
#include <libmesh/cell_tet10.h>
#include <libmesh/cell_tet4.h>
#include <libmesh/edge_edge2.h>
#include <libmesh/edge_edge3.h>
#include <libmesh/edge_edge4.h>
#include <libmesh/edge_inf_edge2.h>
#include <libmesh/face_inf_quad4.h>
#include <libmesh/face_inf_quad6.h>
#include <libmesh/face_quad4.h>
#include <libmesh/face_quad8.h>
#include <libmesh/face_quad9.h>
#include <libmesh/face_tri3.h>
#include <libmesh/face_tri6.h>


// Ignore unused parameter warnings coming from cppunit headers
#include <libmesh/ignore_warnings.h>
#include <cppunit/extensions/HelperMacros.h>
#include <cppunit/TestCase.h>
#include <libmesh/restore_warnings.h>

#include <vector>

#define SIDETEST                                \
  CPPUNIT_TEST( testIsNodeOnSide );             \
  CPPUNIT_TEST( testNodesOnSide );              \
  CPPUNIT_TEST( testSidePtr );                  \
  CPPUNIT_TEST( testSidePtrFill );              \
  CPPUNIT_TEST( testBuildSidePtr );             \
  CPPUNIT_TEST( testBuildSidePtrFill );         \

using namespace libMesh;


template <typename ElemClass, ElemType side_type,
          unsigned short indexbegin, unsigned short indexend>
class SideTest : public CppUnit::TestCase {

private:
  ElemClass elem;
  std::vector<Node> nodes;

public:
  void setUp() {
    elem.set_id() = 0;
    nodes.resize(elem.n_nodes());
    for (auto i : elem.node_index_range())
      {
        nodes[i].set_id() = i;
        elem.set_node(i) = &nodes[i];
      }
  }

  void tearDown() {}

  void testIsNodeOnSide()
  {
    for (auto s : IntRange<unsigned short>(indexbegin, indexend))
      {
        std::unique_ptr<Elem> side = elem.build_side_ptr(s);<commit_msg>Node copy constructor is deprecated.<commit_after>#include <libmesh/elem.h>

#include <libmesh/cell_hex20.h>
#include <libmesh/cell_hex27.h>
#include <libmesh/cell_hex8.h>
#include <libmesh/cell_inf_hex16.h>
#include <libmesh/cell_inf_hex18.h>
#include <libmesh/cell_inf_hex8.h>
#include <libmesh/cell_inf_prism12.h>
#include <libmesh/cell_inf_prism6.h>
#include <libmesh/cell_prism15.h>
#include <libmesh/cell_prism18.h>
#include <libmesh/cell_prism6.h>
#include <libmesh/cell_pyramid13.h>
#include <libmesh/cell_pyramid14.h>
#include <libmesh/cell_pyramid5.h>
#include <libmesh/cell_tet10.h>
#include <libmesh/cell_tet4.h>
#include <libmesh/edge_edge2.h>
#include <libmesh/edge_edge3.h>
#include <libmesh/edge_edge4.h>
#include <libmesh/edge_inf_edge2.h>
#include <libmesh/face_inf_quad4.h>
#include <libmesh/face_inf_quad6.h>
#include <libmesh/face_quad4.h>
#include <libmesh/face_quad8.h>
#include <libmesh/face_quad9.h>
#include <libmesh/face_tri3.h>
#include <libmesh/face_tri6.h>


// Ignore unused parameter warnings coming from cppunit headers
#include <libmesh/ignore_warnings.h>
#include <cppunit/extensions/HelperMacros.h>
#include <cppunit/TestCase.h>
#include <libmesh/restore_warnings.h>

#include <vector>

#define SIDETEST                                \
  CPPUNIT_TEST( testIsNodeOnSide );             \
  CPPUNIT_TEST( testNodesOnSide );              \
  CPPUNIT_TEST( testSidePtr );                  \
  CPPUNIT_TEST( testSidePtrFill );              \
  CPPUNIT_TEST( testBuildSidePtr );             \
  CPPUNIT_TEST( testBuildSidePtrFill );         \

using namespace libMesh;


template <typename ElemClass, ElemType side_type,
          unsigned short indexbegin, unsigned short indexend>
class SideTest : public CppUnit::TestCase {

private:
  ElemClass elem;
  std::vector<std::unique_ptr<Node>> nodes;

public:
  void setUp() {
    elem.set_id() = 0;
    Point dummy;
    for (auto i : elem.node_index_range())
      {
        nodes.push_back(libmesh_make_unique<Node>(dummy, /*id=*/i));
        elem.set_node(i) = nodes[i].get();
      }
  }

  void tearDown() {}

  void testIsNodeOnSide()
  {
    for (auto s : IntRange<unsigned short>(indexbegin, indexend))
      {
        std::unique_ptr<Elem> side = elem.build_side_ptr(s);
{'fraction_non_alphanumeric': 0.12634892086330934, 'fraction_numerical': 0.0170863309352518, 'mean_word_length': 3.80972972972973, 'pattern_counts': {'":': 0, '<': 79, '<?xml version=': 0, '>': 79, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5487975', 'n_tokens_mistral': 1693, 'n_tokens_neox': 1640, 'n_words': 280}