<p>You were right. a few edge cases were not covered in the <strong>public void testInvalidAddresses()</strong></p>
<p>Add those lines will fix it</p>
<pre><code> ```
    //checksum with characters
    assertInvalidAddress("3532-zZ");

    //trailing dash
    assertInvalidAddress("0-");
    assertInvalidAddress("-");

    //too big a number
    assertInvalidAddress("1000000000");
    assertInvalidAddress("1000000000-46");
</code></pre>
<pre><code>Code coverage will show that there is a catch that never actually run. 
</code></pre>
<p>} catch (StringIndexOutOfBoundsException e) {<br>
return AddressValidationResult.invalidAddress(ERROR_INVALID_CHECKSUM_STRUCTURE);<br>
}</p>
<pre><code>It was put there as a defensive measure.

What do you want me to do?
          
Cheers
</code></pre>

<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<br />You are receiving this because you are subscribed to this thread.<br />Reply to this email directly, <a href="https://github.com/bisq-network/bisq/pull/1676#issuecomment-431591929">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe-auth/AkpZtjUrJ5oLtVDSwGo7C7lvDfBXoO4Rks5um0M7gaJpZM4WkYxa">mute the thread</a>.<img src="https://github.com/notifications/beacon/AkpZtnEXjj6_s1OFB63DMi0tQaQmJtbZks5um0M7gaJpZM4WkYxa.gif" height="1" width="1" alt="" /></p>
<script type="application/json" data-scope="inboxmarkup">{"api_version":"1.0","publisher":{"api_key":"05dde50f1d1a384dd78767c55493e4bb","name":"GitHub"},"entity":{"external_key":"github/bisq-network/bisq","title":"bisq-network/bisq","subtitle":"GitHub repository","main_image_url":"https://assets-cdn.github.com/images/email/message_cards/header.png","avatar_image_url":"https://assets-cdn.github.com/images/email/message_cards/avatar.png","action":{"name":"Open in GitHub","url":"https://github.com/bisq-network/bisq"}},"updates":{"snippets":[{"icon":"PERSON","message":"@mordan in #1676: You were right. a few edge cases were not covered in the **public void testInvalidAddresses()**\r\n\r\nAdd those lines will fix it\r\n\r\n     ```\r\n        //checksum with characters\r\n        assertInvalidAddress(\"3532-zZ\");\r\n\r\n        //trailing dash\r\n        assertInvalidAddress(\"0-\");\r\n        assertInvalidAddress(\"-\");\r\n\r\n        //too big a number\r\n        assertInvalidAddress(\"1000000000\");\r\n        assertInvalidAddress(\"1000000000-46\");\r\n\r\n```\r\nCode coverage will show that there is a catch that never actually run. \r\n```\r\n   } catch (StringIndexOutOfBoundsException e) {\r\n                return AddressValidationResult.invalidAddress(ERROR_INVALID_CHECKSUM_STRUCTURE);\r\n   }\r\n```\r\nIt was put there as a defensive measure.\r\n\r\nWhat do you want me to do?\r\n          \r\nCheers"}],"action":{"name":"View Pull Request","url":"https://github.com/bisq-network/bisq/pull/1676#issuecomment-431591929"}}}</script>
<script type="application/ld+json">[
{
"@context": "http://schema.org",
"@type": "EmailMessage",
"potentialAction": {
"@type": "ViewAction",
"target": "https://github.com/bisq-network/bisq/pull/1676#issuecomment-431591929",
"url": "https://github.com/bisq-network/bisq/pull/1676#issuecomment-431591929",
"name": "View Pull Request"
},
"description": "View this Pull Request on GitHub",
"publisher": {
"@type": "Organization",
"name": "GitHub",
"url": "https://github.com"
}
},
{
"@type": "MessageCard",
"@context": "http://schema.org/extensions",
"hideOriginalBody": "false",
"originator": "AF6C5A86-E920-430C-9C59-A73278B5EFEB",
"title": "Re: [bisq-network/bisq] List pasc-coin (#1676)",
"sections": [
{
"text": "",
"activityTitle": "**Charles Bentley**",
"activityImage": "https://assets-cdn.github.com/images/email/message_cards/avatar.png",
"activitySubtitle": "@mordan",
"facts": [

]
}
],
"potentialAction": [
{
"name": "Add a comment",
"@type": "ActionCard",
"inputs": [
{
"isMultiLine": true,
"@type": "TextInput",
"id": "IssueComment",
"isRequired": false
}
],
"actions": [
{
"name": "Comment",
"@type": "HttpPOST",
"target": "https://api.github.com",
"body": "{\n\"commandName\": \"IssueComment\",\n\"repositoryFullName\": \"bisq-network/bisq\",\n\"issueId\": 1676,\n\"IssueComment\": \"{{IssueComment.value}}\"\n}"
}
]
},
{
"name": "Close pull request",
"@type": "HttpPOST",
"target": "https://api.github.com",
"body": "{\n\"commandName\": \"PullRequestClose\",\n\"repositoryFullName\": \"bisq-network/bisq\",\n\"pullRequestId\": 1676\n}"
},
{
"targets": [
{
"os": "default",
"uri": "https://github.com/bisq-network/bisq/pull/1676#issuecomment-431591929"
}
],
"@type": "OpenUri",
"name": "View on GitHub"
},
{
"name": "Unsubscribe",
"@type": "HttpPOST",
"target": "https://api.github.com",
"body": "{\n\"commandName\": \"MuteNotification\",\n\"threadId\": 378637402\n}"
}
],
"themeColor": "26292E"
}
]</script>