From 337d8fe6e3d959ef646879782fa0a817e8f3000c Mon Sep 17 00:00:00 2001 From: Samuel Ryan Date: Thu, 21 Nov 2024 13:54:34 +0800 Subject: [PATCH] test: Simplify ASN test data + test for all properties --- __tests__/fixtures/AS7922.json | 1275 +------------------------------ __tests__/ipinfoWrapper.test.ts | 4 + 2 files changed, 7 insertions(+), 1272 deletions(-) diff --git a/__tests__/fixtures/AS7922.json b/__tests__/fixtures/AS7922.json index f0f1f06..cdd4438 100644 --- a/__tests__/fixtures/AS7922.json +++ b/__tests__/fixtures/AS7922.json @@ -25,1278 +25,9 @@ "size": "131072", "status": "REASSIGNMENT", "domain": "comcast.net" - }, - { - "netblock": "140.99.132.0/22", - "id": "NET-140-99-132-0-22", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "1024", - "status": "REASSIGNMENT", - "domain": "comcast.com" - }, - { - "netblock": "147.191.0.0/16", - "id": "CCC-NET2", - "name": "Comcast Cable Communications", - "country": "US", - "size": "65536", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "162.148.0.0/14", - "id": "CABLE-1", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "262144", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "162.17.0.0/16", - "id": "CBC-CM-4", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "65536", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "165.137.0.0/16", - "id": "CCC-NET2", - "name": "Comcast Cable Communications", - "country": "US", - "size": "65536", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "169.152.0.0/16", - "id": "COMCAST-CET2", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "65536", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "172.244.0.0/16", - "id": "COMCAST-VOIP-4", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "65536", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "173.160.0.0/13", - "id": "CBC-CM-4", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "524288", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "173.214.184.0/23", - "id": "NET-173-214-184-0-23", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "512", - "status": "REASSIGNMENT", - "domain": "comcast.com" - }, - { - "netblock": "173.8.0.0/13", - "id": "CBC-CM-4", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "524288", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "174.140.228.0/23", - "id": "NET-174-140-228-0-23", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "512", - "status": "REASSIGNMENT", - "domain": "comcast.com" - }, - { - "netblock": "174.160.0.0/11", - "id": "COMCAST-VOIP-4", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "2097152", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "174.48.0.0/12", - "id": "JUMPSTART-5", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "1048576", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "184.108.0.0/14", - "id": "COMCAST-VOIP-4", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "262144", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "184.112.0.0/12", - "id": "COMCAST-VOIP-4", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "1048576", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "198.0.0.0/16", - "id": "CBC-CM-4", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "65536", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "198.137.252.0/23", - "id": "CCC-MDC", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "512", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "198.178.8.0/21", - "id": "CCC-NET2", - "name": "Comcast Cable Communications", - "country": "US", - "size": "2048", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "204.11.116.0/22", - "id": "NGT-NET1", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "1024", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "208.39.128.0/18", - "id": "CTI-2TEL", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "16384", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "209.23.192.0/18", - "id": "COMCAST-BUSINESS-BLK4", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "16384", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "216.122.112.0/22", - "id": "NET-216-122-112-0-22", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "1024", - "status": "REASSIGNMENT", - "domain": "comcast.com" - }, - { - "netblock": "216.122.116.0/22", - "id": "NET-216-122-116-0-22", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "1024", - "status": "REASSIGNMENT", - "domain": "comcast.com" - }, - { - "netblock": "216.45.128.0/17", - "id": "COMCAST-BUSINESS-BLK7", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "32768", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "23.24.0.0/15", - "id": "CBC-ALLOC-4", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "131072", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "23.30.0.0/15", - "id": "CBC-CM-4", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "131072", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "23.68.0.0/14", - "id": "COMCAST-VOIP-4", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "262144", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "24.0.0.0/12", - "id": "EASTERNSHORE-1", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "1048576", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "24.104.0.0/17", - "id": "COMCAST-BUSINESS-BLK3", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "32768", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "24.104.128.0/19", - "id": "COMCAST-BUSINESS-BLK3", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "8192", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "24.118.0.0/16", - "id": "CCCH3-14", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "65536", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "24.124.128.0/17", - "id": "EASTERNSHORE-1", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "32768", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "24.125.0.0/16", - "id": "CCCH3-20", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "65536", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "24.126.0.0/15", - "id": "CCCH3-29", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "131072", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "24.128.0.0/16", - "id": "RW2-NORTHEAST-3", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "65536", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "24.129.0.0/17", - "id": "CCCH3-21", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "32768", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "24.130.0.0/15", - "id": "CCCH3-27", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "131072", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "24.147.0.0/16", - "id": "RW2-NORTHEAST-4", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "65536", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "24.153.64.0/19", - "id": "EASTERNSHORE-1", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "8192", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "24.16.0.0/13", - "id": "WASHINGTON-9", - "name": "Comcast Cable Communications", - "country": "US", - "size": "524288", - "status": "REASSIGNMENT", - "domain": "comcast.net" - }, - { - "netblock": "24.218.0.0/16", - "id": "RW2-NORTHEAST-5", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "65536", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "24.245.0.0/18", - "id": "CCCH3-12", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "16384", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "24.30.0.0/17", - "id": "CCCH3-4", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "32768", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "24.34.0.0/16", - "id": "CCCH3-8", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "65536", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "24.40.0.0/18", - "id": "CCC-WCDC", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "16384", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "24.40.64.0/20", - "id": "CCC-WCDC", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "4096", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "24.60.0.0/14", - "id": "RW2-NORTHEAST-1", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "262144", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "24.91.0.0/16", - "id": "RW2-NORTHEAST-2", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "65536", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "24.98.0.0/15", - "id": "CCCH3-2", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "131072", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "50.128.0.0/9", - "id": "CCCH3-4", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "8388608", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "50.220.178.0/24", - "id": "CCCH3-4", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "256", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "50.221.162.0/24", - "id": "CCCH3-4", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "256", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "50.73.0.0/16", - "id": "CBC-ALLOC-4", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "65536", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "50.76.0.0/14", - "id": "CBC-ALLOC-4", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "262144", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "64.139.64.0/19", - "id": "CBC-CM-2", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "8192", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "64.56.32.0/19", - "id": "CTI-TEL", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "8192", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "65.34.128.0/17", - "id": "CCCH3-24", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "32768", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "65.96.0.0/16", - "id": "CCCH3-19", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "65536", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "65.97.0.0/19", - "id": "COMCAST-46", - "name": "Comcast Cable Communications Holdings, Inc", - "country": "US", - "size": "8192", - "status": "REASSIGNMENT", - "domain": "comcast.net" - }, - { - "netblock": "66.176.0.0/15", - "id": "CCCH3-25", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "131072", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "66.208.192.0/18", - "id": "CBC-CM", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "16384", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "66.229.0.0/16", - "id": "CCCH3-32", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "65536", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "66.240.0.0/18", - "id": "CTI-3TEL", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "16384", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "66.30.0.0/15", - "id": "RW2-NORTHEAST-6", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "131072", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "66.41.0.0/16", - "id": "CCCH3-10", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "65536", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "66.56.0.0/18", - "id": "CCCH3-3", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "16384", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "67.160.0.0/11", - "id": "COMCAST", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "2097152", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "68.32.0.0/11", - "id": "JUMPSTART-1", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "2097152", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "68.80.0.0/13", - "id": "JUMPSTART-2", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "524288", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "69.136.0.0/13", - "id": "JUMPSTART-3", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "524288", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "69.180.0.0/15", - "id": "CCCH3-33", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "131072", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "69.240.0.0/12", - "id": "JUMPSTART-4", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "1048576", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "70.88.0.0/14", - "id": "CBC-CM-3", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "262144", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "71.192.0.0/12", - "id": "ATT-COMCAST", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "1048576", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "71.224.0.0/12", - "id": "JUMPSTART-5", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "1048576", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "71.24.0.0/14", - "id": "COMCAST-VOIP-2", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "262144", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "71.56.0.0/13", - "id": "CCCH-3-34", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "524288", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "72.55.0.0/17", - "id": "COMCAST-BUSINESS-BLK6", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "32768", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "73.0.0.0/8", - "id": "CABLE-1", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "16777216", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "74.16.0.0/12", - "id": "COMCAST-VOIP-3", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "1048576", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "74.92.0.0/14", - "id": "CBC-CM-4", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "262144", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "75.144.0.0/13", - "id": "CBC-CM-5", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "524288", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "75.64.0.0/13", - "id": "CCCH-3-34", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "524288", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "75.72.0.0/15", - "id": "MINNESOTA-12", - "name": "Comcast Cable Communications Holdings, Inc", - "country": "US", - "size": "131072", - "status": "REASSIGNMENT", - "domain": "comcast.net" - }, - { - "netblock": "75.74.0.0/16", - "id": "MIAMI-23", - "name": "Comcast Cable Communications Holdings, Inc", - "country": "US", - "size": "65536", - "status": "REASSIGNMENT", - "domain": "comcast.net" - }, - { - "netblock": "75.75.0.0/17", - "id": "RICHMOND-23", - "name": "Comcast Cable Communications Holdings, Inc", - "country": "US", - "size": "32768", - "status": "REASSIGNMENT", - "domain": "comcast.net" - }, - { - "netblock": "75.75.128.0/18", - "id": "PA-41", - "name": "Comcast Cable Communications Holdings, Inc", - "country": "US", - "size": "16384", - "status": "REASSIGNMENT", - "domain": "comcast.net" - }, - { - "netblock": "76.128.0.0/11", - "id": "JUMPSTART-5", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "2097152", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "76.16.0.0/12", - "id": "WESTERN-1", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "1048576", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "76.96.0.0/11", - "id": "JUMPSTART-5", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "2097152", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "96.112.0.0/13", - "id": "NEW-ENGLAND-CDM-6", - "name": "Comcast IP Services, L.L.C.", - "country": "US", - "size": "524288", - "status": "REASSIGNMENT", - "domain": "comcast.net" - }, - { - "netblock": "96.120.0.0/14", - "id": "CABLE-1", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "262144", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "96.124.0.0/16", - "id": "BAWA-CCS-CM-1", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "65536", - "status": "REASSIGNMENT", - "domain": "comcast.com" - }, - { - "netblock": "96.128.0.0/10", - "id": "CABLE-1", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "4194304", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "96.192.0.0/11", - "id": "COMCAST-EX-S-1", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "2097152", - "status": "REASSIGNMENT", - "domain": "comcast.com" - }, - { - "netblock": "96.64.0.0/11", - "id": "CABLE-1", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "2097152", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "96.96.0.0/12", - "id": "COMCAST-EX-5", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "1048576", - "status": "REASSIGNMENT", - "domain": "comcast.com" - }, - { - "netblock": "98.192.0.0/10", - "id": "JUMPSTART-5", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "4194304", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "98.32.0.0/11", - "id": "COMCAST-VOIP-4", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "2097152", - "status": "ALLOCATION", - "domain": "comcast.com" - } - ], - "prefixes6": [ - { - "netblock": "2001:558::/29", - "id": "COMCAST6NET", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "633825300114114700748351602688", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "2601::/20", - "id": "COMCAST6NET", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "324518553658426726783156020576256", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "2603:2000::/20", - "id": "COMCAST6NET", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "324518553658426726783156020576256", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "2603:3000::/24", - "id": "COMCAST6NET", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "20282409603651670423947251286016", - "status": "ALLOCATION", - "domain": "comcast.com" - }, - { - "netblock": "2620:fd:8000::/48", - "id": "CIMQAV6", - "name": "Comcast Cable Communications, LLC", - "country": "US", - "size": "1208925819614629174706176", - "status": "ALLOCATION", - "domain": "comcast.com" } ], - "peers": [ - "1273", - "109", - "17151", - "7016", - "17054", - "36410", - "2516", - "32934", - "5400", - "17035", - "397601", - "7342", - "20253", - "3292", - "16276", - "3257", - "46489", - "1239", - "2914", - "7979", - "33490", - "6204", - "33667", - "31898", - "19255", - "714", - "398465", - "57976", - "3356", - "32308", - "19231", - "40428", - "715", - "33666", - "30704", - "5670", - "13331", - "2906", - "17676", - "33650", - "6327", - "237", - "23352", - "33548", - "8103", - "23154", - "30036", - "33668", - "20473", - "32244", - "60068", - "33491", - "13649", - "37721", - "7843", - "33654", - "22697", - "30103", - "54113", - "812", - "55256", - "22299", - "30058", - "15133", - "16509", - "11164", - "7018", - "22326", - "42", - "35777", - "2635", - "1547", - "20115", - "16406", - "11608", - "19551", - "1299", - "30081", - "12222", - "6507", - "14010", - "23470", - "5769", - "2828", - "25671", - "393444", - "53264", - "577", - "2559", - "33655", - "7015", - "20214", - "36732", - "396986", - "62785", - "393415", - "394041", - "18779", - "33656", - "36236", - "6939", - "212465", - "45489", - "32590", - "13335", - "53766", - "396415", - "36213", - "6830", - "33651", - "7029", - "33661", - "53991", - "6128", - "23344", - "49544", - "3491", - "174", - "4837", - "1280", - "15305", - "27400", - "25875", - "4134", - "62537", - "40627", - "33659", - "26554", - "4258", - "26558", - "33662", - "40763", - "18957", - "33657", - "33665", - "21508", - "11396", - "22103", - "6461", - "46844", - "19679", - "33293", - "20940", - "14340", - "22773", - "33287", - "40109", - "15169", - "33652", - "18450", - "54040", - "6762", - "395487", - "8075", - "5511", - "6453", - "62642", - "19855", - "12956", - "13367", - "5607", - "4637", - "11114", - "13445", - "33660", - "701", - "63311", - "40676", - "22909", - "36498", - "9304", - "35873", - "3778", - "7473", - "7725", - "27552", - "6653", - "33489", - "46450", - "16524", - "22822", - "22258", - "395856", - "4766", - "63199", - "3320", - "4229", - "14042", - "36351", - "3223", - "395610", - "21976", - "64289", - "852", - "45758", - "8047" - ], - "upstreams": [ - "6453", - "1299", - "5511", - "6830", - "174", - "6461", - "3257", - "6939", - "12956", - "7018", - "701", - "3356", - "3320", - "6762", - "2914", - "3491" - ], - "downstreams": [ - "398465", - "32244", - "22299", - "25875", - "8103", - "30103", - "32308", - "32590", - "12956", - "15305", - "40763", - "63199", - "6653", - "6830", - "18450", - "19231", - "64289", - "17035", - "40676", - "17054", - "40428", - "2635", - "33662", - "33651", - "33287", - "33668", - "33490", - "33491", - "33652", - "33660", - "33659", - "33667", - "13367", - "395487", - "45758", - "40109", - "109", - "3223", - "22103", - "40627", - "1299", - "701", - "12222", - "54113", - "30081", - "212465", - "14010", - "7018", - "53766", - "22326", - "395610", - "16276", - "13335", - "53264", - "46844", - "63311", - "17151", - "394041", - "6507", - "19855", - "2914", - "33654", - "22258", - "33650", - "33661", - "33656", - "33666", - "33665", - "33655", - "21508", - "36498", - "19255", - "62537", - "4258", - "26558", - "54040", - "33657", - "22909", - "7725", - "30704", - "33489", - "7015", - "20214", - "7016", - "393415", - "14042", - "23470", - "36732", - "396415", - "30058", - "30036", - "33548", - "393444", - "18957", - "36410", - "11396", - "35777", - "8047", - "16406", - "13649", - "11608", - "6453", - "3491", - "25671", - "6461", - "36213", - "3320", - "5511", - "13331", - "397601", - "23154", - "7979", - "3356", - "6762", - "60068", - "174" - ] + "peers": ["1273", "109"], + "upstreams": ["6453", "1299"], + "downstreams": ["398465", "32244"] } diff --git a/__tests__/ipinfoWrapper.test.ts b/__tests__/ipinfoWrapper.test.ts index ee6e2c4..e5b6ad1 100644 --- a/__tests__/ipinfoWrapper.test.ts +++ b/__tests__/ipinfoWrapper.test.ts @@ -89,6 +89,10 @@ describe("IPinfoWrapper", () => { expect(data.domain).toEqual("comcast.com"); expect(data.num_ips).not.toBeFalsy(); expect(data.type).toEqual("isp"); + expect(data.prefixes.length).toEqual(2); + expect(data.peers.length).toEqual(2); + expect(data.upstreams.length).toEqual(2); + expect(data.downstreams.length).toEqual(2); } });