LCOV - code coverage report
Current view: top level - shared - Caravan.cpp (source / functions) Hit Total Coverage
Test: code-coverage.info.cleaned Lines: 20 22 90.9 %
Date: 2023-01-28 00:08:57 Functions: 7 8 87.5 %

          Line data    Source code
       1             : #include <shared.hpp>
       2             : 
       3             : using namespace shared;
       4             : 
       5           3 : Caravan::Caravan()
       6             : {
       7           3 :     this->position = {0, 0};
       8           3 :     this->used = false;
       9           3 : }
      10             : 
      11           2 : Caravan::Caravan(std::array<unsigned, 2> position, std::string player)
      12             : {
      13           2 :     this->position = position;
      14           2 :     this->player = player;
      15           2 : }
      16             : 
      17           3 : std::array<unsigned, 2> Caravan::getPosition()
      18             : {
      19           3 :     return this->position;
      20             : }
      21             : 
      22           2 : void Caravan::setPos(std::array<unsigned, 2> position)
      23             : {
      24           2 :     this->position = position;
      25           2 : }
      26             : 
      27           2 : void Caravan::setUsed(bool used)
      28             : {
      29           2 :     this->used = used;
      30           2 : }
      31             : 
      32           3 : bool Caravan::isUsed()
      33             : {
      34           3 :     return this->used;
      35             : }
      36             : 
      37           0 : ElementEnum Caravan::getType()
      38             : {
      39           0 :     return ElementEnum::caravan;
      40             : }
      41             : 
      42           2 : std::string Caravan::getPlayerName()
      43             : {
      44           2 :     return this->player;
      45             : }

Generated by: LCOV version 1.14