Skip to content

Commit

Permalink
make dev as default chain id and fixup warning when CI check (#725)
Browse files Browse the repository at this point in the history
* make dev as  default chain id and fixup warning when CI check

* remove unused module

* fixup module use for testcase
  • Loading branch information
baichuan3 authored Aug 30, 2023
1 parent e690515 commit 5486900
Show file tree
Hide file tree
Showing 13 changed files with 20 additions and 24 deletions.
1 change: 0 additions & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions crates/rooch-config/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@ once_cell = { workspace = true }
clap = { workspace = true }
dirs-next = { workspace = true }
schemars = {workspace = true }
proptest = { default-features = false, optional = true, workspace = true }
proptest-derive = { default-features = false, optional = true, workspace = true }
proptest = { optional = true, workspace = true }
proptest-derive = { optional = true, workspace = true }

rooch-key = { workspace = true }
rooch-types = { workspace = true }
Expand Down
6 changes: 3 additions & 3 deletions crates/rooch-framework/sources/coin.move
Original file line number Diff line number Diff line change
Expand Up @@ -756,7 +756,7 @@ module rooch_framework::coin {
let destination_ctx = storage_context::new_test_context_random(signer::address_of(destination), b"test_tx1");
let mod_account_ctx = storage_context::new_test_context_random(signer::address_of(mod_account), b"test_tx2");

init_for_test(&mut mod_account_ctx, mod_account);
init_for_test(&mut mod_account_ctx);
initialize_entry<FakeCoin>(
&mut mod_account_ctx,
mod_account,
Expand Down Expand Up @@ -808,7 +808,7 @@ module rooch_framework::coin {
let destination_ctx = storage_context::new_test_context_random(signer::address_of(destination), b"test_tx1");
let mod_account_ctx = storage_context::new_test_context_random(signer::address_of(mod_account), b"test_tx2");

init_for_test(&mut mod_account_ctx, mod_account);
init_for_test(&mut mod_account_ctx);
initialize_entry<FakeCoin>(&mut mod_account_ctx, mod_account, b"Fake Coin", b"FCD", 9);
init_account_coin_store(&mut mod_account_ctx, mod_account);
init_account_coin_store(&mut source_ctx, source);
Expand All @@ -834,7 +834,7 @@ module rooch_framework::coin {
let destination_ctx = storage_context::new_test_context_random(signer::address_of(destination), b"test_tx1");
let mod_account_ctx = storage_context::new_test_context_random(signer::address_of(mod_account), b"test_tx2");

init_for_test(&mut mod_account_ctx, mod_account);
init_for_test(&mut mod_account_ctx);
initialize_entry<FakeCoin>(&mut mod_account_ctx, mod_account, b"Fake Coin", b"FCD", 9);
init_account_coin_store(&mut mod_account_ctx, mod_account);
init_account_coin_store(&mut source_ctx, source);
Expand Down
4 changes: 2 additions & 2 deletions crates/rooch-key/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@ tiny-bip39 = { workspace = true }
rooch-types = { workspace = true }
move-core-types = { workspace = true }
moveos-types = { workspace = true }
proptest = { default-features = false, optional = true, workspace = true }
proptest-derive = { default-features = false, optional = true, workspace = true }
proptest = {optional = true, workspace = true }
proptest-derive = {optional = true, workspace = true }

[dev-dependencies]
proptest = { workspace = true }
Expand Down
4 changes: 2 additions & 2 deletions crates/rooch-types/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,8 @@ moveos-types = { workspace = true }
moveos-stdlib = { workspace = true }
moveos = { workspace = true }

proptest = { default-features = false, optional = true, workspace = true }
proptest-derive = { default-features = false, optional = true, workspace = true }
proptest = { optional = true, workspace = true }
proptest-derive = { optional = true, workspace = true }

[dev-dependencies]
proptest = { workspace = true }
Expand Down
4 changes: 2 additions & 2 deletions crates/rooch-types/src/chain_id.rs
Original file line number Diff line number Diff line change
Expand Up @@ -77,10 +77,10 @@ impl Into<u64> for ChainID {
#[repr(u64)]
pub enum BuiltinChainID {
/// A ephemeral network just for developer test.
#[default]
Dev = CHAIN_ID_DEV,
/// Rooch test network,
/// Rooch test network.
/// The data on the chain will be cleaned up periodically.
#[default]
Test = CHAIN_ID_TEST,
/// Rooch main net.
Main = CHAIN_ID_MAIN,
Expand Down
1 change: 0 additions & 1 deletion crates/rooch-types/src/transaction/rooch.rs
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,6 @@ impl RoochTransaction {
#[cfg(test)]
pub fn mock() -> RoochTransaction {
use crate::address::RoochSupportedAddress;
use crate::crypto::Signature;
use fastcrypto::ed25519::Ed25519KeyPair;
use fastcrypto::traits::KeyPair;
use move_core_types::{identifier::Identifier, language_storage::ModuleId};
Expand Down
2 changes: 1 addition & 1 deletion crates/rooch/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -34,10 +34,10 @@ hex = { workspace = true }
regex = { workspace = true }
serde-reflection = { workspace = true }
serde-generate = { workspace = true }
bcs-ext = { package = "bcs-ext", workspace = true }
rust-embed = { workspace = true }
rocket = { workspace = true }
parking_lot = { workspace = true }
bcs-ext = { workspace = true }

move-bytecode-utils = { workspace = true }
move-binary-format = { workspace = true }
Expand Down
5 changes: 2 additions & 3 deletions examples/private_generics/sources/private_generics.move
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,8 @@ module rooch_examples::Test1 {
}

module rooch_examples::Test3 {
use rooch_examples::Test1::Box;
use rooch_examples::Test1::create_box;
use rooch_examples::Test1::box_value;
#[test_only]
use rooch_examples::Test1::{create_box, Box, box_value};

struct InnerData has key, store, drop, copy {
v: u64,
Expand Down
2 changes: 1 addition & 1 deletion moveos/metrics/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ rust-version = { workspace = true }

[dependencies]
anyhow = { workspace = true }
prometheus = { default-features = false, workspace = true }
prometheus = {workspace = true }
serde_json = { features = ["arbitrary_precision"], workspace = true }
futures = { optional = true, workspace = true }
hyper = { features = ["full"], optional = true, workspace = true }
Expand Down
4 changes: 2 additions & 2 deletions moveos/moveos-commons/accumulator/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,15 @@ edition = "2021"

[dependencies]
anyhow = { workspace = true }
bcs-ext = { package = "bcs-ext", workspace = true }
itertools = { default-features = false, workspace = true }
itertools = { workspace = true }
log = { workspace = true }
lru = { workspace = true }
once_cell = { workspace = true }
parking_lot = { workspace = true }
serde = { workspace = true }
mirai-annotations = { workspace = true }
moveos-types = { workspace = true }
bcs-ext = { workspace = true }

[dev-dependencies]
proptest = { workspace = true }
Expand Down
3 changes: 1 addition & 2 deletions moveos/moveos-store/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -35,5 +35,4 @@ moveos-stdlib = { workspace = true }
raw-store = { workspace = true }
moveos-common = { workspace = true }
moveos-config = { workspace = true }
accumulator = { workspace = true }
bcs-ext = { package = "bcs-ext", workspace = true }
accumulator = { workspace = true }
4 changes: 2 additions & 2 deletions moveos/moveos-types/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@ schemars = { workspace = true }
primitive-types = { workspace = true }
tiny-keccak = { workspace = true, features = ["keccak", "sha3"] }
fastcrypto = { workspace = true }
proptest = { default-features = false, optional = true, workspace = true }
proptest-derive = { default-features = false, optional = true, workspace = true }
proptest = { optional = true, workspace = true }
proptest-derive = { optional = true, workspace = true }

move-core-types = { workspace = true }
move-resource-viewer = { workspace = true }
Expand Down

0 comments on commit 5486900

Please sign in to comment.