-
Notifications
You must be signed in to change notification settings - Fork 134
Adapt acceptance tests to use estimate gas query from SDK (#11183) #11432
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 11 commits
b0309ea
49953b8
10555f1
07ad56e
7a4b72b
ba65593
08f02bb
78d8a12
2bd86f9
eb32060
20aac1e
855b17b
1f461ff
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,26 @@ | ||
| // SPDX-License-Identifier: Apache-2.0 | ||
|
|
||
| package org.hiero.mirror.test.e2e.acceptance.config; | ||
|
|
||
| import java.net.URI; | ||
| import java.net.URISyntaxException; | ||
|
|
||
| public interface ApiProperties { | ||
| String getBaseUrl(); | ||
|
Check notice on line 9 in test/src/test/java/org/hiero/mirror/test/e2e/acceptance/config/ApiProperties.java
|
||
|
|
||
| default String getEndpoint() throws URISyntaxException { | ||
|
Check notice on line 11 in test/src/test/java/org/hiero/mirror/test/e2e/acceptance/config/ApiProperties.java
|
||
| var endpoint = getBaseUrl(); | ||
|
|
||
| if (endpoint != null) { | ||
| URI uri = new URI(endpoint); | ||
| if (uri.getPort() == -1) { | ||
| var https = uri.getScheme().equals("https"); | ||
|
Check warning on line 17 in test/src/test/java/org/hiero/mirror/test/e2e/acceptance/config/ApiProperties.java
|
||
| var trimmedEndpoint = endpoint.replaceFirst("/api/v1/?$", ""); | ||
|
Check warning on line 18 in test/src/test/java/org/hiero/mirror/test/e2e/acceptance/config/ApiProperties.java
|
||
| endpoint = trimmedEndpoint + ":" + (https ? 443 : 80); | ||
| } | ||
| endpoint = (endpoint.replaceFirst("^https?://", "").replaceFirst("/api/v1/?$", "")); | ||
|
Check notice on line 21 in test/src/test/java/org/hiero/mirror/test/e2e/acceptance/config/ApiProperties.java
|
||
| } | ||
|
|
||
| return endpoint; | ||
| } | ||
| } | ||
Uh oh!
There was an error while loading. Please reload this page.