BEGIN { $| = 1;
print
"1..46\n"
; }
END {
print
"not ok 1\n"
unless
$loaded
;}
$loaded
= 1;
$i
= 1;
result(
$i
);
my
$quantitationtypemap
;
{
local
$SIG
{__WARN__} =
sub
{
'IGNORE'
};
$quantitationtypemap
= Bio::MAGE::BioAssayData::QuantitationTypeMap->new();
}
result(
$quantitationtypemap
->isa(
'Bio::MAGE::BioAssayData::QuantitationTypeMap'
));
result(
$quantitationtypemap
->
package
() eq
q[BioAssayData]
);
result(
$quantitationtypemap
->class_name() eq
q[Bio::MAGE::BioAssayData::QuantitationTypeMap]
);
{
local
$SIG
{__WARN__} =
sub
{
'IGNORE'
};
$quantitationtypemap
= Bio::MAGE::BioAssayData::QuantitationTypeMap->new(
identifier
=> 1,
name
=> 2);
}
result (
$quantitationtypemap
->getIdentifier() == 1);
$quantitationtypemap
->setIdentifier(1);
result (
$quantitationtypemap
->getIdentifier() == 1);
result (
$quantitationtypemap
->getName() == 2);
$quantitationtypemap
->setName(2);
result (
$quantitationtypemap
->getName() == 2);
my
%assns
= Bio::MAGE::BioAssayData::QuantitationTypeMap->associations();
my
$assn
;
{
local
$SIG
{__WARN__} =
sub
{
'IGNORE'
};
$quantitationtypemap
= Bio::MAGE::BioAssayData::QuantitationTypeMap->new(
sourcesQuantitationType
=> [Bio::MAGE::QuantitationType::QuantitationType->new()],
targetQuantitationType
=> Bio::MAGE::QuantitationType::QuantitationType->new(),
protocolApplications
=> [Bio::MAGE::Protocol::ProtocolApplication->new()],
security
=> Bio::MAGE::AuditAndSecurity::Security->new(),
auditTrail
=> [Bio::MAGE::AuditAndSecurity::Audit->new()],
descriptions
=> [Bio::MAGE::Description::Description->new()],
propertySets
=> [Bio::MAGE::NameValueType->new()]);
}
my
$sourcesquantitationtype_assn
;
{
local
$SIG
{__WARN__} =
sub
{
'IGNORE'
};
$sourcesquantitationtype_assn
= Bio::MAGE::QuantitationType::QuantitationType->new();
}
result (UNIVERSAL::isa(
$quantitationtypemap
->getSourcesQuantitationType->[0],
q[Bio::MAGE::QuantitationType::QuantitationType]
));
result (
$quantitationtypemap
->setSourcesQuantitationType([
$sourcesquantitationtype_assn
]));
result (UNIVERSAL::isa(
$quantitationtypemap
->getSourcesQuantitationType,
'ARRAY'
)
and
scalar
@{
$quantitationtypemap
->getSourcesQuantitationType()} == 1
and
$quantitationtypemap
->getSourcesQuantitationType->[0] ==
$sourcesquantitationtype_assn
);
$quantitationtypemap
->addSourcesQuantitationType(
$sourcesquantitationtype_assn
);
result (UNIVERSAL::isa(
$quantitationtypemap
->getSourcesQuantitationType,
'ARRAY'
)
and
scalar
@{
$quantitationtypemap
->getSourcesQuantitationType()} == 2
and
$quantitationtypemap
->getSourcesQuantitationType->[0] ==
$sourcesquantitationtype_assn
and
$quantitationtypemap
->getSourcesQuantitationType->[1] ==
$sourcesquantitationtype_assn
);
(
$assn
) =
$assns
{sourcesQuantitationType};
result(is_object(
$assn
)
and
$assn
->isa(
'Bio::MAGE::Association'
)
and
defined
$assn
->description(),
and
defined
$assn
->cardinality(),
and
grep
{
$_
eq
$assn
->cardinality} (
'0..1'
,
'1'
,
'1..N'
,
'0..N'
),
and
defined
$assn
->is_ref(),
and (
$assn
->is_ref() == 0 or
$assn
->is_ref() == 1),
and
defined
$assn
->rank(),
and
$assn
->rank(),
and
defined
$assn
->ordered(),
and (
$assn
->ordered() == 0 or
$assn
->ordered() == 1),
and
defined
$assn
->class_name(),
and
$assn
->class_name(),
and
defined
$assn
->name(),
and
$assn
->name(),
);
my
$targetquantitationtype_assn
;
{
local
$SIG
{__WARN__} =
sub
{
'IGNORE'
};
$targetquantitationtype_assn
= Bio::MAGE::QuantitationType::QuantitationType->new();
}
result (UNIVERSAL::isa(
$quantitationtypemap
->getTargetQuantitationType,
q[Bio::MAGE::QuantitationType::QuantitationType]
));
result (
$quantitationtypemap
->setTargetQuantitationType(
$targetquantitationtype_assn
) ==
$targetquantitationtype_assn
);
result (
$quantitationtypemap
->getTargetQuantitationType() ==
$targetquantitationtype_assn
);
(
$assn
) =
$assns
{targetQuantitationType};
result(is_object(
$assn
)
and
$assn
->isa(
'Bio::MAGE::Association'
)
and
defined
$assn
->description(),
and
defined
$assn
->cardinality(),
and
grep
{
$_
eq
$assn
->cardinality} (
'0..1'
,
'1'
,
'1..N'
,
'0..N'
),
and
defined
$assn
->is_ref(),
and (
$assn
->is_ref() == 0 or
$assn
->is_ref() == 1),
and
defined
$assn
->rank(),
and
$assn
->rank(),
and
defined
$assn
->ordered(),
and (
$assn
->ordered() == 0 or
$assn
->ordered() == 1),
and
defined
$assn
->class_name(),
and
$assn
->class_name(),
and
defined
$assn
->name(),
and
$assn
->name(),
);
my
$protocolapplications_assn
;
{
local
$SIG
{__WARN__} =
sub
{
'IGNORE'
};
$protocolapplications_assn
= Bio::MAGE::Protocol::ProtocolApplication->new();
}
result (UNIVERSAL::isa(
$quantitationtypemap
->getProtocolApplications->[0],
q[Bio::MAGE::Protocol::ProtocolApplication]
));
result (
$quantitationtypemap
->setProtocolApplications([
$protocolapplications_assn
]));
result (UNIVERSAL::isa(
$quantitationtypemap
->getProtocolApplications,
'ARRAY'
)
and
scalar
@{
$quantitationtypemap
->getProtocolApplications()} == 1
and
$quantitationtypemap
->getProtocolApplications->[0] ==
$protocolapplications_assn
);
$quantitationtypemap
->addProtocolApplications(
$protocolapplications_assn
);
result (UNIVERSAL::isa(
$quantitationtypemap
->getProtocolApplications,
'ARRAY'
)
and
scalar
@{
$quantitationtypemap
->getProtocolApplications()} == 2
and
$quantitationtypemap
->getProtocolApplications->[0] ==
$protocolapplications_assn
and
$quantitationtypemap
->getProtocolApplications->[1] ==
$protocolapplications_assn
);
(
$assn
) =
$assns
{protocolApplications};
result(is_object(
$assn
)
and
$assn
->isa(
'Bio::MAGE::Association'
)
and
defined
$assn
->description(),
and
defined
$assn
->cardinality(),
and
grep
{
$_
eq
$assn
->cardinality} (
'0..1'
,
'1'
,
'1..N'
,
'0..N'
),
and
defined
$assn
->is_ref(),
and (
$assn
->is_ref() == 0 or
$assn
->is_ref() == 1),
and
defined
$assn
->rank(),
and
$assn
->rank(),
and
defined
$assn
->ordered(),
and (
$assn
->ordered() == 0 or
$assn
->ordered() == 1),
and
defined
$assn
->class_name(),
and
$assn
->class_name(),
and
defined
$assn
->name(),
and
$assn
->name(),
);
my
$security_assn
;
{
local
$SIG
{__WARN__} =
sub
{
'IGNORE'
};
$security_assn
= Bio::MAGE::AuditAndSecurity::Security->new();
}
result (UNIVERSAL::isa(
$quantitationtypemap
->getSecurity,
q[Bio::MAGE::AuditAndSecurity::Security]
));
result (
$quantitationtypemap
->setSecurity(
$security_assn
) ==
$security_assn
);
result (
$quantitationtypemap
->getSecurity() ==
$security_assn
);
(
$assn
) =
$assns
{security};
result(is_object(
$assn
)
and
$assn
->isa(
'Bio::MAGE::Association'
)
and
defined
$assn
->description(),
and
defined
$assn
->cardinality(),
and
grep
{
$_
eq
$assn
->cardinality} (
'0..1'
,
'1'
,
'1..N'
,
'0..N'
),
and
defined
$assn
->is_ref(),
and (
$assn
->is_ref() == 0 or
$assn
->is_ref() == 1),
and
defined
$assn
->rank(),
and
$assn
->rank(),
and
defined
$assn
->ordered(),
and (
$assn
->ordered() == 0 or
$assn
->ordered() == 1),
and
defined
$assn
->class_name(),
and
$assn
->class_name(),
and
defined
$assn
->name(),
and
$assn
->name(),
);
my
$audittrail_assn
;
{
local
$SIG
{__WARN__} =
sub
{
'IGNORE'
};
$audittrail_assn
= Bio::MAGE::AuditAndSecurity::Audit->new();
}
result (UNIVERSAL::isa(
$quantitationtypemap
->getAuditTrail->[0],
q[Bio::MAGE::AuditAndSecurity::Audit]
));
result (
$quantitationtypemap
->setAuditTrail([
$audittrail_assn
]));
result (UNIVERSAL::isa(
$quantitationtypemap
->getAuditTrail,
'ARRAY'
)
and
scalar
@{
$quantitationtypemap
->getAuditTrail()} == 1
and
$quantitationtypemap
->getAuditTrail->[0] ==
$audittrail_assn
);
$quantitationtypemap
->addAuditTrail(
$audittrail_assn
);
result (UNIVERSAL::isa(
$quantitationtypemap
->getAuditTrail,
'ARRAY'
)
and
scalar
@{
$quantitationtypemap
->getAuditTrail()} == 2
and
$quantitationtypemap
->getAuditTrail->[0] ==
$audittrail_assn
and
$quantitationtypemap
->getAuditTrail->[1] ==
$audittrail_assn
);
(
$assn
) =
$assns
{auditTrail};
result(is_object(
$assn
)
and
$assn
->isa(
'Bio::MAGE::Association'
)
and
defined
$assn
->description(),
and
defined
$assn
->cardinality(),
and
grep
{
$_
eq
$assn
->cardinality} (
'0..1'
,
'1'
,
'1..N'
,
'0..N'
),
and
defined
$assn
->is_ref(),
and (
$assn
->is_ref() == 0 or
$assn
->is_ref() == 1),
and
defined
$assn
->rank(),
and
$assn
->rank(),
and
defined
$assn
->ordered(),
and (
$assn
->ordered() == 0 or
$assn
->ordered() == 1),
and
defined
$assn
->class_name(),
and
$assn
->class_name(),
and
defined
$assn
->name(),
and
$assn
->name(),
);
my
$descriptions_assn
;
{
local
$SIG
{__WARN__} =
sub
{
'IGNORE'
};
$descriptions_assn
= Bio::MAGE::Description::Description->new();
}
result (UNIVERSAL::isa(
$quantitationtypemap
->getDescriptions->[0],
q[Bio::MAGE::Description::Description]
));
result (
$quantitationtypemap
->setDescriptions([
$descriptions_assn
]));
result (UNIVERSAL::isa(
$quantitationtypemap
->getDescriptions,
'ARRAY'
)
and
scalar
@{
$quantitationtypemap
->getDescriptions()} == 1
and
$quantitationtypemap
->getDescriptions->[0] ==
$descriptions_assn
);
$quantitationtypemap
->addDescriptions(
$descriptions_assn
);
result (UNIVERSAL::isa(
$quantitationtypemap
->getDescriptions,
'ARRAY'
)
and
scalar
@{
$quantitationtypemap
->getDescriptions()} == 2
and
$quantitationtypemap
->getDescriptions->[0] ==
$descriptions_assn
and
$quantitationtypemap
->getDescriptions->[1] ==
$descriptions_assn
);
(
$assn
) =
$assns
{descriptions};
result(is_object(
$assn
)
and
$assn
->isa(
'Bio::MAGE::Association'
)
and
defined
$assn
->description(),
and
defined
$assn
->cardinality(),
and
grep
{
$_
eq
$assn
->cardinality} (
'0..1'
,
'1'
,
'1..N'
,
'0..N'
),
and
defined
$assn
->is_ref(),
and (
$assn
->is_ref() == 0 or
$assn
->is_ref() == 1),
and
defined
$assn
->rank(),
and
$assn
->rank(),
and
defined
$assn
->ordered(),
and (
$assn
->ordered() == 0 or
$assn
->ordered() == 1),
and
defined
$assn
->class_name(),
and
$assn
->class_name(),
and
defined
$assn
->name(),
and
$assn
->name(),
);
my
$propertysets_assn
;
{
local
$SIG
{__WARN__} =
sub
{
'IGNORE'
};
$propertysets_assn
= Bio::MAGE::NameValueType->new();
}
result (UNIVERSAL::isa(
$quantitationtypemap
->getPropertySets->[0],
q[Bio::MAGE::NameValueType]
));
result (
$quantitationtypemap
->setPropertySets([
$propertysets_assn
]));
result (UNIVERSAL::isa(
$quantitationtypemap
->getPropertySets,
'ARRAY'
)
and
scalar
@{
$quantitationtypemap
->getPropertySets()} == 1
and
$quantitationtypemap
->getPropertySets->[0] ==
$propertysets_assn
);
$quantitationtypemap
->addPropertySets(
$propertysets_assn
);
result (UNIVERSAL::isa(
$quantitationtypemap
->getPropertySets,
'ARRAY'
)
and
scalar
@{
$quantitationtypemap
->getPropertySets()} == 2
and
$quantitationtypemap
->getPropertySets->[0] ==
$propertysets_assn
and
$quantitationtypemap
->getPropertySets->[1] ==
$propertysets_assn
);
(
$assn
) =
$assns
{propertySets};
result(is_object(
$assn
)
and
$assn
->isa(
'Bio::MAGE::Association'
)
and
defined
$assn
->description(),
and
defined
$assn
->cardinality(),
and
grep
{
$_
eq
$assn
->cardinality} (
'0..1'
,
'1'
,
'1..N'
,
'0..N'
),
and
defined
$assn
->is_ref(),
and (
$assn
->is_ref() == 0 or
$assn
->is_ref() == 1),
and
defined
$assn
->rank(),
and
$assn
->rank(),
and
defined
$assn
->ordered(),
and (
$assn
->ordered() == 0 or
$assn
->ordered() == 1),
and
defined
$assn
->class_name(),
and
$assn
->class_name(),
and
defined
$assn
->name(),
and
$assn
->name(),
);
result (
$quantitationtypemap
->isa(
q[Bio::MAGE::BioEvent::Map]
));
result (
$quantitationtypemap
->isa(
q[Bio::MAGE::BioEvent::BioEvent]
));
result (
$quantitationtypemap
->isa(
q[Bio::MAGE::Identifiable]
));
result (
$quantitationtypemap
->isa(
q[Bio::MAGE::Describable]
));
result (
$quantitationtypemap
->isa(
q[Bio::MAGE::Extendable]
));