-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #111 from JimmyShi22/master
Release v1.0.0-rc4
- Loading branch information
Showing
94 changed files
with
13,881 additions
and
2,744 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,28 +1,69 @@ | ||
#!/bin/bash | ||
set -e | ||
|
||
# gradle build check | ||
bash gradlew build | ||
|
||
# Non SM node test | ||
echo " Not SM ============>>>> " | ||
echo " Not SM ============>>>> " | ||
echo " Not SM ============>>>> " | ||
|
||
# download build_chain.sh to build fisco-bcos block chain | ||
curl -LO https://github.com/FISCO-BCOS/FISCO-BCOS/releases/download/v2.4.0/build_chain.sh && chmod u+x build_chain.sh | ||
curl -LO https://github.com/FISCO-BCOS/FISCO-BCOS/releases/download/v2.5.0/build_chain.sh && chmod u+x build_chain.sh | ||
echo "127.0.0.1:4 agency1 1,2,3" > ipconf | ||
|
||
bash build_chain.sh -f ipconf | ||
./nodes/127.0.0.1/fisco-bcos -v | ||
cat nodes/127.0.0.1/node0/config.ini | egrep sm_crypto | ||
|
||
bash nodes/127.0.0.1/start_all.sh | ||
./nodes/127.0.0.1/fisco-bcos -v | ||
# integration testing | ||
mkdir -p src/integTest/resources/chains/bcos | ||
cp -r nodes/127.0.0.1/sdk/* src/integTest/resources/chains/bcos | ||
cp src/test/resources/stub.toml src/integTest/resources/chains/bcos/ | ||
cp -r src/test/resources/accounts src/integTest/resources/ | ||
cp -r src/test/resources/contract src/integTest/resources/ | ||
mkdir -p src/integTest/resources/solidity | ||
cp src/main/resources/* src/integTest/resources/solidity | ||
cp src/test/resources/contract/* src/integTest/resources/solidity | ||
bash gradlew integTest | ||
bash gradlew jacocoTestReport | ||
|
||
# Verify format | ||
bash gradlew verifyGoogleJavaFormat | ||
# clean | ||
bash nodes/127.0.0.1/stop_all.sh | ||
bash nodes/127.0.0.1/stop_all.sh | ||
bash nodes/127.0.0.1/stop_all.sh | ||
rm -rf nodes | ||
|
||
# gradle build check | ||
bash gradlew build | ||
bash gradlew test | ||
bash gradlew jacocoTestReport | ||
# SM node test | ||
echo " SM ============>>>> " | ||
echo " SM ============>>>> " | ||
echo " SM ============>>>> " | ||
|
||
# download build_chain.sh to build fisco-bcos block chain | ||
curl -LO https://github.com/FISCO-BCOS/FISCO-BCOS/releases/download/v2.5.0/build_chain.sh && chmod u+x build_chain.sh | ||
echo "127.0.0.1:4 agency1 1,2,3" > ipconf | ||
bash build_chain.sh -f ipconf -g | ||
./nodes/127.0.0.1/fisco-bcos -v | ||
cat nodes/127.0.0.1/node0/config.ini | egrep sm_crypto | ||
|
||
bash nodes/127.0.0.1/start_all.sh | ||
# integration testing | ||
mkdir -p src/integTest/resources/chains/bcos | ||
cp nodes/127.0.0.1/sdk/* src/integTest/resources/chains/bcos | ||
cp -r nodes/127.0.0.1/sdk/* src/integTest/resources/chains/bcos | ||
cp src/test/resources/stub.toml src/integTest/resources/chains/bcos/ | ||
cp -r src/test/resources/accounts src/integTest/resources/ | ||
cp -r src/test/resources/contract src/integTest/resources/ | ||
sed -i.bak 's/BCOS2/GM_BCOS2/g' src/integTest/resources/chains/bcos/stub.toml | ||
cat src/integTest/resources/chains/bcos/stub.toml | ||
mkdir -p src/integTest/resources/accounts | ||
cp -r src/test/resources/accounts/bcos src/integTest/resources/accounts | ||
cp -r src/test/resources/accounts/gm_bcos src/integTest/resources/accounts/fisco | ||
mkdir -p src/integTest/resources/solidity | ||
cp src/main/resources/* src/integTest/resources/solidity | ||
cp src/test/resources/contract/* src/integTest/resources/solidity | ||
bash gradlew integTest | ||
./gradlew jacocoTestReport | ||
|
||
# clean | ||
bash nodes/127.0.0.1/stop_all.sh | ||
bash nodes/127.0.0.1/stop_all.sh | ||
bash nodes/127.0.0.1/stop_all.sh | ||
rm -rf nodes |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
v1.0.0-rc3 | ||
v1.0.0-rc4 |
23 changes: 23 additions & 0 deletions
23
src/integTest/java/com/webank/wecross/stub/bcos/integration/AsyncToSync.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
package com.webank.wecross.stub.bcos.integration; | ||
|
||
import java.util.concurrent.Semaphore; | ||
|
||
class AsyncToSync { | ||
AsyncToSync() { | ||
try { | ||
semaphore.acquire(1); | ||
} catch (InterruptedException e) { | ||
Thread.currentThread().interrupt(); | ||
} | ||
} | ||
|
||
public Semaphore getSemaphore() { | ||
return semaphore; | ||
} | ||
|
||
public void setSemaphore(Semaphore semaphore) { | ||
this.semaphore = semaphore; | ||
} | ||
|
||
public Semaphore semaphore = new Semaphore(1, true); | ||
}; |
Oops, something went wrong.