File: SCU.cpp

package info (click to toggle)
odil 0.13.0-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 5,476 kB
  • sloc: cpp: 55,982; python: 3,947; javascript: 460; xml: 182; makefile: 99; sh: 36
file content (35 lines) | stat: -rw-r--r-- 826 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
#define BOOST_TEST_MODULE SCU
#include <boost/test/unit_test.hpp>

#include "odil/SCU.h"
#include "odil/registry.h"

#include "../PeerFixtureBase.h"

struct Fixture: public PeerFixtureBase
{
    Fixture()
    : PeerFixtureBase({
        {
            1, odil::registry::Verification,
            {odil::registry::ImplicitVRLittleEndian}, 
            odil::AssociationParameters::PresentationContext::Role::SCU
        }
    })
    {
        // Nothing else
    }
};

BOOST_FIXTURE_TEST_CASE(DefaultConstructor, Fixture)
{
    odil::SCU const scu(this->association);
    BOOST_CHECK_EQUAL(scu.get_affected_sop_class(), "");
}

BOOST_FIXTURE_TEST_CASE(AffectedSOPClassUID, Fixture)
{
    odil::SCU scu(this->association);
    scu.set_affected_sop_class("1.2.3");
    BOOST_CHECK_EQUAL(scu.get_affected_sop_class(), "1.2.3");
}