public static String resolveRegistryContract(String chainId) {
        final Long chainIdLong = Long.parseLong(chainId);
        if (chainIdLong.equals(ChainIdLong.MAINNET)) {
            return MAINNET;
        } else if (chainIdLong.equals(ChainIdLong.ROPSTEN)) {
            return ROPSTEN;
        } else if (chainIdLong.equals(ChainIdLong.RINKEBY)) {
            return RINKEBY;
        } else if (chainIdLong.equals(ChainIdLong.GOERLI)) {
            return GOERLI;
        } else if (chainIdLong.equals(ChainIdLong.SEPOLIA)) {
            return SEPOLIA;
        } else if (chainIdLong.equals(ChainIdLong.LINEA)) {
            return LINEA;
        } else if (chainIdLong.equals(ChainIdLong.LINEA_SEPOLIA)) {
            return LINEA_SEPOLIA;
        } else {
            throw new EnsResolutionException(
                    "Unable to resolve ENS registry contract for network id: " + chainId);
        }
    }
@Test
    public void testResolveRegistryContract() {
        assertEquals(resolveRegistryContract(ChainIdLong.MAINNET + ""), (MAINNET));
        assertEquals(resolveRegistryContract(ChainIdLong.ROPSTEN + ""), (ROPSTEN));
        assertEquals(resolveRegistryContract(ChainIdLong.RINKEBY + ""), (RINKEBY));
        assertEquals(resolveRegistryContract(ChainIdLong.SEPOLIA + ""), (SEPOLIA));
        assertEquals(resolveRegistryContract(ChainIdLong.LINEA + ""), (LINEA));
        assertEquals(resolveRegistryContract(ChainIdLong.LINEA_SEPOLIA + ""), (LINEA_SEPOLIA));
    }