Skip to content
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

ci: Solo integration #883

Merged
merged 40 commits into from
Jan 31, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
40 commits
Select commit Hold shift + click to select a range
a069965
feat: Install Solo in CI
gsstoykov Jan 23, 2025
5c63a48
ci: Remove redundant CI steps
gsstoykov Jan 23, 2025
4abf4ad
ci: Add solo run commands
gsstoykov Jan 23, 2025
fe6ac42
feat: Remove clean commands for solo
gsstoykov Jan 23, 2025
286631c
feat: Install Kubernetes
gsstoykov Jan 23, 2025
e342eb7
ci: Add kind
gsstoykov Jan 23, 2025
58c390e
ci: Install kind from curl
gsstoykov Jan 23, 2025
7a96e10
ci: Add superuser
gsstoykov Jan 23, 2025
87a3bab
ci: Chmod for kind
gsstoykov Jan 23, 2025
a60132a
ci: Call outside of repo command
gsstoykov Jan 23, 2025
a3ab814
ci: Solo deploy, run and start
gsstoykov Jan 23, 2025
caf2550
ci: Open GRPC port for solo
gsstoykov Jan 23, 2025
c578122
ci: Add kubectl to deps
gsstoykov Jan 23, 2025
6280d23
ci: Move kubectl to bin
gsstoykov Jan 23, 2025
39049eb
ci: Solo namespace not found fix
gsstoykov Jan 23, 2025
cb3f933
ci: Revert namespace
gsstoykov Jan 23, 2025
cc33707
ci: Add integration test steps
gsstoykov Jan 28, 2025
8ebdbd4
ci: deply mirror node
gsstoykov Jan 28, 2025
f478159
ci: add namespace to mirror node deploy
gsstoykov Jan 28, 2025
ee2d815
ci: Variable for namespaces added
gsstoykov Jan 28, 2025
ad0aa34
ci: revert to using solo-e2e instead of variables
gsstoykov Jan 28, 2025
60b4011
ci: Add mirror node deploy with the altered commands
gsstoykov Jan 28, 2025
86ef205
Merge branch 'main' into 00874-add-ci-support-for-testing-with-the-so…
gsstoykov Jan 28, 2025
2c6e65f
ci: Disable AddressBookQuery and add 5551 port export
gsstoykov Jan 28, 2025
d2e46fc
ci: Temporary disable parallel runs of the tests
gsstoykov Jan 28, 2025
5de51fd
ci: Removed incorrect test
gsstoykov Jan 28, 2025
b23bb87
ci: Disable testing jobs for debug
gsstoykov Jan 28, 2025
3ee129a
ci: Disable infinite looping topic integration tests
gsstoykov Jan 28, 2025
6a65658
ci: set 0.33.0 version of Solo and export the contract service port
gsstoykov Jan 29, 2025
9d2f301
ci: revert the Solo version to 0.34.0
gsstoykov Jan 29, 2025
6e1dc00
ci: Downgrade Solo to 0.32.0
gsstoykov Jan 29, 2025
d75fb63
ci: Revert to 0.34.0 and disable flaky tests for the version
gsstoykov Jan 29, 2025
e08477e
ci: Move Solo start commands
gsstoykov Jan 29, 2025
30289f6
ci: define local-node,solo matrix
gsstoykov Jan 29, 2025
e42b013
ci: Remove local-node from workflow
gsstoykov Jan 30, 2025
460f74e
ci: Downgrade platformVersion to 0.57.0
gsstoykov Jan 30, 2025
bba74dd
fix: Fix broken AccountBalance test
gsstoykov Jan 30, 2025
09e3169
fix: Disable unresolved tests
gsstoykov Jan 30, 2025
f4ad3cb
chore: Add solo disable comments
gsstoykov Jan 30, 2025
fc40779
Merge branch 'main' into 00874-add-ci-support-for-testing-with-the-so…
gsstoykov Jan 30, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
36 changes: 28 additions & 8 deletions .github/workflows/zxc-build-library.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -105,9 +105,6 @@ jobs:
with:
node-version: 22

- name: Install Local Node
run: sudo npm install -g @hashgraph/[email protected]

- name: Install Linux Prerequisites
run: |
sudo apt-get update
Expand Down Expand Up @@ -155,8 +152,34 @@ jobs:
${{ steps.cgroup.outputs.exec }} cmake --build -j 6 --preset ${{ matrix.preset }}-release
echo "::endgroup::"

- name: Start the local node
run: npx hedera start --verbose=trace --detached --network-tag=0.57.0
- name: Install Solo
run: sudo npm install -g @hashgraph/[email protected]

- name: Install Solo Required Tools
run: |
sudo curl -LO "https://dl.k8s.io/release/$(curl -L -s https://dl.k8s.io/release/stable.txt)/bin/linux/amd64/kubectl"
sudo chmod +x ./kubectl
sudo mv ./kubectl /usr/local/bin/kubectl
sudo curl -Lo ./kind https://kind.sigs.k8s.io/dl/v0.26.0/kind-linux-amd64
sudo chmod +x ./kind
sudo mv ./kind /usr/local/bin/kind

- name: Start Solo
run: |
export SOLO_CLUSTER_NAME=solo-e2e
export SOLO_NAMESPACE=solo-e2e
export SOLO_CLUSTER_SETUP_NAMESPACE=fullstack-setup
kind create cluster -n "${SOLO_CLUSTER_NAME}"
solo init
solo node keys -i node1 --gossip-keys --tls-keys
solo cluster setup
solo network deploy -i node1 -n solo-e2e
solo node setup -i node1 -n solo-e2e -t v0.57.0
solo node start -i node1 -n solo-e2e
kubectl port-forward svc/haproxy-node1-svc -n "${SOLO_NAMESPACE}" 50211:50211 &
solo mirror-node deploy -n "${SOLO_NAMESPACE}" --pinger true
kubectl port-forward $(cut -d' ' -f1 <<<$(kubectl get pods -n solo-e2e | grep mirror-rest-)) 5551:5551 -n solo-e2e &
kubectl port-forward $(cut -d' ' -f1 <<<$(kubectl get pods -n solo-e2e | grep mirror-web)) 8545:8545 -n solo-e2e &

- name: Start CTest suite (Debug)
run: ${{ steps.cgroup.outputs.exec }} ctest -j 6 -C Debug --test-dir build/${{ matrix.preset }}-debug --output-on-failure
Expand All @@ -165,9 +188,6 @@ jobs:
if: github.event.pull_request.merged == true
run: ${{ steps.cgroup.outputs.exec }} ctest -j 6 -C Debug --test-dir build/${{ matrix.preset }}-release --output-on-failure

- name: Stop the local node
run: sudo npx @hashgraph/hedera-local stop

- name: Compute Short SHA
id: sha
run: echo "short=$(echo -n "${{ github.sha }}" | cut -c1-8)" >> $GITHUB_OUTPUT
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,8 @@ class AccountBalanceQueryIntegrationTests : public BaseIntegrationTest
};

//-----
TEST_F(AccountBalanceQueryIntegrationTests, AccountId)
// Disabled until Solo adds test accounts similar to Local Node
TEST_F(AccountBalanceQueryIntegrationTests, DISABLED_AccountId)
{
// Given
AccountBalance accountBalance;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ class AddressBookQueryIntegrationTests : public BaseIntegrationTest
};

//-----
TEST_F(AddressBookQueryIntegrationTests, ExecuteAddressBookQuery)
TEST_F(AddressBookQueryIntegrationTests, DISABLED_ExecuteAddressBookQuery)
{
// Given / When / Then
EXPECT_NO_THROW(const NodeAddressBook nodeAddressBook =
Expand Down
35 changes: 0 additions & 35 deletions src/sdk/tests/integration/ClientIntegrationTests.cc
Original file line number Diff line number Diff line change
Expand Up @@ -107,38 +107,3 @@ TEST_F(ClientIntegrationTests, ConnectToLocalNode)
EXPECT_NE(client.getOperatorPublicKey(), nullptr);
EXPECT_FALSE(newAccountId.toString().empty());
}

//-----
TEST_F(ClientIntegrationTests, SetNetworkIsWorkingCorrectly)
rwalworth marked this conversation as resolved.
Show resolved Hide resolved
{
// Given
const AccountId accountId_3 = AccountId::fromString("0.0.3");
const AccountId accountId_4 = AccountId::fromString("0.0.4");
const AccountId accountId_5 = AccountId::fromString("0.0.5");
const AccountId accountId_6 = AccountId::fromString("0.0.6");
const AccountId accountId_7 = AccountId::fromString("0.0.7");

AccountBalance accountBalance_3;
AccountBalance accountBalance_4;
AccountBalance accountBalance_5;
AccountBalance accountBalance_6;
AccountBalance accountBalance_7;

std::unordered_map<std::string, AccountId> networkMap;
networkMap.insert(std::pair<std::string, AccountId>("34.94.106.61:50211", accountId_3));
networkMap.insert(std::pair<std::string, AccountId>("35.237.119.55:50211", accountId_4));
networkMap.insert(std::pair<std::string, AccountId>("35.245.27.193:50211", accountId_5));

Client client = Client::forNetwork(networkMap);

// When / Then
std::unordered_map<std::string, AccountId> newNetworkMap;
newNetworkMap.insert(std::pair<std::string, AccountId>("35.237.119.55:50211", accountId_6));
newNetworkMap.insert(std::pair<std::string, AccountId>("35.245.27.193:50211", accountId_7));

client.setNetwork(newNetworkMap);

// When / Then
ASSERT_NO_THROW(accountBalance_6 = AccountBalanceQuery().setAccountId(accountId_6).execute(client));
ASSERT_NO_THROW(accountBalance_7 = AccountBalanceQuery().setAccountId(accountId_7).execute(client));
}
Original file line number Diff line number Diff line change
Expand Up @@ -233,7 +233,8 @@ TEST_F(ScheduleCreateTransactionIntegrationTests, CanSignScheduleAndWaitForExpir
}

//-----
TEST_F(ScheduleCreateTransactionIntegrationTests, CannotScheduleOneYearIntoTheFuture)
// Disabled until Solo triage
TEST_F(ScheduleCreateTransactionIntegrationTests, DISABLED_CannotScheduleOneYearIntoTheFuture)
{
// Given
std::shared_ptr<PrivateKey> operatorKey;
Expand Down Expand Up @@ -278,7 +279,8 @@ TEST_F(ScheduleCreateTransactionIntegrationTests, CannotScheduleOneYearIntoTheFu
}

//-----
TEST_F(ScheduleCreateTransactionIntegrationTests, CannotScheduleInThePast)
// Disabled until Solo triage
TEST_F(ScheduleCreateTransactionIntegrationTests, DISABLED_CannotScheduleInThePast)
{
// Given
std::shared_ptr<PrivateKey> operatorKey;
Expand Down Expand Up @@ -417,7 +419,8 @@ TEST_F(ScheduleCreateTransactionIntegrationTests, CanSignWithMultisigAndUpdateSi
}

//-----
TEST_F(ScheduleCreateTransactionIntegrationTests, CanExecuteWithShortExpirationTime)
// Disabled until Solo triage
TEST_F(ScheduleCreateTransactionIntegrationTests, DISABLED_CanExecuteWithShortExpirationTime)
{
// Given
std::shared_ptr<PrivateKey> operatorKey;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,8 @@ class TopicMessageQueryIntegrationTests : public BaseIntegrationTest
};

//-----
TEST_F(TopicMessageQueryIntegrationTests, ExecuteTopicMessageQuery)
// Disabled until Solo triage
TEST_F(TopicMessageQueryIntegrationTests, DISABLED_ExecuteTopicMessageQuery)
{
// Given
const std::string topicMessage = "Hello from HCS!";
Expand Down Expand Up @@ -79,7 +80,8 @@ TEST_F(TopicMessageQueryIntegrationTests, ExecuteTopicMessageQuery)
}

//-----
TEST_F(TopicMessageQueryIntegrationTests, CanReceiveLargeTopicMessage)
// Disabled until Solo triage
TEST_F(TopicMessageQueryIntegrationTests, DISABLED_CanReceiveLargeTopicMessage)
gsstoykov marked this conversation as resolved.
Show resolved Hide resolved
{
// Given
const std::string topicMessage =
Expand Down
Loading