• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

localstack / localstack / 22709357475

05 Mar 2026 08:35AM UTC coverage: 59.732% (-27.2%) from 86.974%
22709357475

Pull #13880

github

web-flow
Merge 28fcab93c into 710618057
Pull Request #13880: Firehose: Replace TaggingService

12 of 12 new or added lines in 2 files covered. (100.0%)

20464 existing lines in 510 files now uncovered.

45290 of 75822 relevant lines covered (59.73%)

0.6 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

45.71
/localstack-core/localstack/services/route53resolver/utils.py
1
import re
1✔
2

3
from localstack.aws.api.route53resolver import ResourceNotFoundException, ValidationException
1✔
4
from localstack.services.ec2.models import get_ec2_backend
1✔
5
from localstack.utils.aws.arns import ARN_PARTITION_REGEX
1✔
6
from localstack.utils.strings import get_random_hex
1✔
7

8

9
def get_route53_resolver_firewall_rule_group_id():
1✔
UNCOV
10
    return f"rslvr-frg-{get_random_hex(17)}"
×
11

12

13
def get_route53_resolver_firewall_domain_list_id():
1✔
UNCOV
14
    return f"rslvr-fdl-{get_random_hex(17)}"
×
15

16

17
def get_route53_resolver_firewall_rule_group_association_id():
1✔
18
    return f"rslvr-frgassoc-{get_random_hex(17)}"
×
19

20

21
def get_resolver_query_log_config_id():
1✔
UNCOV
22
    return f"rslvr-rqlc-{get_random_hex(17)}"
×
23

24

25
def get_route53_resolver_query_log_config_association_id():
1✔
26
    return f"rslvr-qlcassoc-{get_random_hex(17)}"
×
27

28

29
def get_firewall_config_id():
1✔
30
    return f"rslvr-fc-{get_random_hex(17)}"
×
31

32

33
def validate_priority(priority):
1✔
34
    # value of priority can be null in case of update
35
    if priority:
×
36
        if priority not in range(100, 9900):
×
37
            raise ValidationException(
×
38
                f"[RSLVR-02017] The priority value you provided is reserved. Provide a number between '100' and '9900'. Trace Id: '{get_trace_id()}'"
39
            )
40

41

42
def validate_mutation_protection(mutation_protection):
1✔
43
    if mutation_protection:
×
44
        if mutation_protection not in ["ENABLED", "DISABLED"]:
×
45
            raise ValidationException(
×
46
                f"[RSLVR-02018] The mutation protection value you provided is reserved. Provide a value of 'ENABLED' or 'DISABLED'. Trace Id: '{get_trace_id()}'"
47
            )
48

49

50
def validate_destination_arn(destination_arn):
1✔
UNCOV
51
    arn_pattern = rf"{ARN_PARTITION_REGEX}:(kinesis|logs|s3):?(.*)"
×
UNCOV
52
    if not re.match(arn_pattern, destination_arn):
×
53
        raise ResourceNotFoundException(
×
54
            f"[RSLVR-01014] An Amazon Resource Name (ARN) for the destination is required. Trace Id: '{get_trace_id()}'"
55
        )
56

57

58
def validate_vpc(vpc_id: str, region: str, account_id: str):
1✔
59
    backend = get_ec2_backend(account_id, region)
×
60

61
    if vpc_id not in backend.vpcs:
×
62
        raise ValidationException(
×
63
            f"[RSLVR-02025] Can't find the resource with ID : '{vpc_id}'. Trace Id: '{get_trace_id()}'"
64
        )
65

66

67
def get_trace_id():
1✔
UNCOV
68
    return f"1-{get_random_hex(8)}-{get_random_hex(24)}"
×
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc