Lines Matching defs:self
75 def __init__(self, _bytes): argument
78 def to_bytes(self): argument
81 def to_dict(self, d=None): argument
87 def __len__(self): argument
96 def __init__(self, _bytes): argument
99 def to_bytes(self): argument
102 def to_dict(self, d=None): argument
107 def __len__(self): argument
114 def parse(self, data, context): argument
120 def __init__(self): argument
126 def __init__(self, header, data, _type): argument
132 def type(self): argument
135 def to_bytes(self): argument
138 def __len__(self): argument
342 def test_should_convert_IPv6_header_to_bytes_when_to_bytes_method_is_called(self): argument
368 def test_should_create_IPv6Header_when_from_bytes_classmethod_is_called(self): argument
396 def test_should_return_proper_header_length_when_IPv6Packet_object_is_called_in_len(self): argument
410 def test_should_convert_UDP_header_to_bytes_when_to_bytes_method_is_called(self): argument
428 def test_should_create_UDPHeader_when_from_bytes_classmethod_is_called(self): argument
447 def test_should_return_proper_header_length_when_UDPHeader_object_is_called_in_len(self): argument
457 def test_should_return_17_when_type_property_is_called(self): argument
467 def test_should_convert_icmp_message_header_to_bytes_when_to_bytes_method_is_called(self): argument
483 def test_should_create_ICMPv6Header_when_to_bytes_classmethod_is_called(self): argument
499 def test_should_return_proper_header_length_when_ICMPv6Header_object_is_called_in_len(self): argument
512 …ould_build_IPv6Packet_with_ICMP_payload_from_well_know_values_when_to_bytes_method_is_called(self): argument
545 …hould_build_IPv6Packet_with_UDP_payload_from_well_know_values_when_to_bytes_method_is_called(self): argument
576 def test_should_create_IPv6Packet_with_MPL_and_ICMP_when_to_bytes_method_is_called(self): argument
619 …ould_create_IPv6Packet_without_any_extension_header_with_ICMP_when_to_bytes_method_is_called(self): argument
651 def test_should_set_message_info_field_when_to_bytes_method_is_called(self): argument
676 def test_should_creates_bytes_from_UDPHeader_and_payload_when_to_bytes_method_is_called(self): argument
701 def test_shold_convert_IPv6_fragment_header_to_bytes_when_to_bytes_method_is_called(self): argument
719 def test_should_create_FragmentHeader_when_from_bytes_classmethod_is_called(self): argument
741 def test_should_creates_bytes_from_ICMPv6Header_and_body_when_to_bytes_method_is_called(self): argument
763 def _calculate_hdr_ext_len(self, payload_len): argument
775 def _calculate_required_padding(self, content_length): argument
783 def create_padding(self, padding_length): argument
792 def test_should_create_bytes_from_HopByHop_when_to_bytes_method_is_called(self): argument
813 def test_should_convert_MPLOption_to_bytes_when_to_bytes_method_is_called(self): argument
830 def test_should_create_MPLOption_when_to_bytes_method_is_called_with_data(self): argument
850 def test_check_if_mpl_seed_id_length_values_was_not_changed(self): argument
856 def test_should_return_proper_length_when_len_is_called_with_mpl_option_object(self): argument
876 def test_should_convert_HopByHopOption_to_bytes_when_to_bytes_method_is_called(self): argument
891 …test_should_return_length_of_HopByHopOption_when_len_is_called_with_hop_by_hop_option_object(self): argument
910 def test_should_convert_HopByHopOptionHeader_to_bytes_when_to_bytes_method_is_called(self): argument
924 def test_should_create_HopByHopOptionHeader_when_to_bytes_method_is_called_with_data(self): argument
938 def test_should_return_proper_length_when_len_is_called_with_HopByHopOptionHeader_object(self): argument
955 def _calculate_hdr_ext_len(self, payload_length): argument
963 def padding(self, content_length): argument
977 def test_should_create_HopByHop_object_instance_when_to_bytes_method_is_called_with_data(self): argument
1001 … def test_should_raise_RuntimeError_when_no_option_factory_is_set_and_parse_method_is_called(self): argument
1019 def test_should_produce_MPLOption_from_bytes_when_to_bytes_method_is_called_with_data(self): argument
1045 …_should_create_payload_from_data_when_src_port_factory_is_defined_and_parse_method_is_called(self): argument
1062 …_should_create_payload_from_data_when_dst_port_factory_is_defined_and_parse_method_is_called(self): argument
1079 …st_should_raise_RuntimeError_when_parse_method_is_called_but_required_factory_is_not_defined(self): argument
1095 def test_should_produce_UDPDatagram_from_bytes_when_to_bytes_method_is_called_with_data(self): argument
1120 def test_should_set_src_and_dst_port_in_message_info_when_parse_method_is_called(self): argument
1154 def test_should_produce_ICMPv6_from_bytes_when_to_bytes_method_is_called_with_data(self): argument
1174 …f test_should_raise_RuntimeError_when_method_parse_is_called_but_body_factory_is_not_present(self): argument
1191 def test_should_create_BytesPayload_when_from_bytes_class_method_is_called(self): argument
1201 …_should_return_exactly_the_same_data_as_passed_to_constructor_when_to_bytes_method_is_called(self): argument
1212 …_return_the_same_len_as_data_passed_to_constructor_when_len_is_called_on_BytesPayload_object(self): argument
1226 def test_convert_ICMPv6_echo_body_to_data_when_to_bytes_method_is_called(self): argument
1241 def test_should_create_ICMPv6EchoBody_from_data_when_from_bytes_classmethod_is_called(self): argument
1258 def test_should_build_ICMPv6EchoBody_from_well_know_values_when_to_bytes_method_is_called(self): argument
1281 def test_should_build_ICMPv6EchoBody_when_to_bytes_method_is_called(self): argument
1305 …test_should_convert_ICMPv6DestinationUnreachable_to_bytearray_when_to_bytes_method_is_called(self): argument
1317 …st_should_convert_bytearray_to_ICMPv6DestinationUnreachable_when_from_bytes_method_is_called(self): argument
1328 def test_should_raise_RuntimeError_when_from_bytes_method_is_called(self): argument
1341 def test_should_create_ICMPv6DestinationUnreachable_when_parse_method_is_called(self): argument
1358 def test_should_create_UDPHeader_when_to_bytes_method_is_called(self): argument
1382 def test_should_create_option_from_bytearray_when_to_bytes_method_is_called(self): argument
1387 def parse(self, data, message_info): argument