Skip to content

Commit

Permalink
ci: improve python test and release script
Browse files Browse the repository at this point in the history
  • Loading branch information
vemonet committed May 30, 2024
1 parent 4b6cb36 commit 8d0660c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 10 deletions.
7 changes: 4 additions & 3 deletions python/tests/test_nanopub.py
Original file line number Diff line number Diff line change
Expand Up @@ -47,9 +47,10 @@ def test_check():

def test_sign():
np = Nanopub(rdf_str)
np = np.sign(profile=profile)
assert np.info()["trusty_hash"]
assert not np.info()["published"]
signed = np.sign(profile=profile)
assert not np.info()["trusty_hash"]
assert signed.info()["trusty_hash"]
assert not signed.info()["published"]

def test_publish():
np = Nanopub(rdf_str).publish(profile=profile, server_url=None)
Expand Down
7 changes: 0 additions & 7 deletions scripts/release.sh
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,8 @@ new_version=$1
echo ""
echo " 🏔️ Update version in Cargo.toml"
echo ""
files=(
"lib/Cargo.toml"
"cli/Cargo.toml"
"python/Cargo.toml"
"js/Cargo.toml"
)
sed -i "s/^version = \"[0-9]*\.[0-9]*\.[0-9]*\"\$/version = \"$new_version\"/" "Cargo.toml"
sed -i "s/nanopub = { version = \"[0-9]*\.[0-9]*\.[0-9]*\"/nanopub = { version = \"$new_version\"/" "Cargo.toml"
echo "🔼 Updated version in Cargo.toml"

git cliff -o CHANGELOG.md --tag $new_version
git add Cargo.toml */Cargo.toml CHANGELOG.md
Expand Down

0 comments on commit 8d0660c

Please sign in to comment.