LCOV - code coverage report
Current view: top level - cell - SimulationConfig.cpp (source / functions) Hit Total Coverage
Test: coverage.info Lines: 7 8 87.5 %
Date: 2025-12-06 00:15:40 Functions: 2 2 100.0 %

          Line data    Source code
       1             : #include "SimulationConfig.hpp"
       2             : 
       3          13 : cell::config::MembraneType& cell::findMembraneTypeByName(cell::SimulationConfig& simulationConfig,
       4             :                                                          std::string membraneTypeName)
       5             : {
       6          13 :     if (membraneTypeName == "" || membraneTypeName == cell::config::cellMembraneTypeName)
       7           5 :         return simulationConfig.cellMembraneType;
       8             : 
       9           8 :     auto membraneType = std::find_if(simulationConfig.membraneTypes.begin(), simulationConfig.membraneTypes.end(),
      10          11 :                                      [&](const auto& membraneType) { return membraneType.name == membraneTypeName; });
      11           8 :     if (membraneType == simulationConfig.membraneTypes.end())
      12           0 :         throw ExceptionWithLocation("No membrane type \"" + membraneTypeName + "\" found in the config");
      13             : 
      14           8 :     return *membraneType;
      15             : }

Generated by: LCOV version 1.14