This is an automated email from the ASF dual-hosted git repository.
chaokunyang pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/fory.git
The following commit(s) were added to refs/heads/main by this push:
new 6efb56f02 chore(rust): rename fory-tests to tests (#2783)
6efb56f02 is described below
commit 6efb56f026fa810ed6878db448a44d5dd5416008
Author: Shawn Yang <[email protected]>
AuthorDate: Mon Oct 20 17:00:26 2025 +0800
chore(rust): rename fory-tests to tests (#2783)
## Why?
tests is more idiomatic to AI coding
## What does this PR do?
rename fory-tests to tests
## Related issues
<!--
Is there any related issue? If this PR closes them you say say
fix/closes:
- #xxxx0
- #xxxx1
- Fixes #xxxx2
-->
## Does this PR introduce any user-facing change?
<!--
If any user-facing interface changes, please [open an
issue](https://github.com/apache/fory/issues/new/choose) describing the
need to do so and update the document if necessary.
Delete section if not applicable.
-->
- [ ] Does this PR introduce any public API change?
- [ ] Does this PR introduce any binary protocol compatibility change?
## Benchmark
<!--
When the PR has an impact on performance (if you don't know whether the
PR will have an impact on performance, you can submit the PR first, and
if it will have impact on performance, the code reviewer will explain
it), be sure to attach a benchmark data here.
Delete section if not applicable.
-->
---
AGENTS.md | 4 ++--
CONTRIBUTING.md | 2 +-
docs/guide/DEVELOPMENT.md | 2 +-
rust/README.md | 4 ++--
rust/fory/src/lib.rs | 2 +-
rust/tests/Cargo.toml | 2 +-
rust/tests/tests/compatible/test_struct.rs | 2 +-
rust/tests/tests/test_complex_struct.rs | 2 +-
rust/tests/tests/test_cross_language.rs | 2 +-
9 files changed, 11 insertions(+), 11 deletions(-)
diff --git a/AGENTS.md b/AGENTS.md
index 18786ac25..5d6bb2739 100644
--- a/AGENTS.md
+++ b/AGENTS.md
@@ -140,7 +140,7 @@ cargo clippy --all-targets --all-features -- -D warnings
cargo test --features tests
# run specific test
-cargo test -p fory-tests --test $test_file $test_method
+cargo test -p tests --test $test_file $test_method
# run specific test under subdirectory
cargo test --test mod $dir$::$test_file::$test_method
@@ -356,7 +356,7 @@ Fory serialization for every language is implemented
independently to minimize t
- **fory-test-core**: Core test utilities and data generators
-- **fory-testsuite**: Complex test suite for issues reported by users and hard
to reproduce using simple test cases
+- **testsuite**: Complex test suite for issues reported by users and hard to
reproduce using simple test cases
- **benchmark**: Benchmark suite based on jmh
diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md
index b89a77ca7..91192cbaf 100644
--- a/CONTRIBUTING.md
+++ b/CONTRIBUTING.md
@@ -63,7 +63,7 @@ go test -v fory_xlang_test.go
cd rust
cargo test
# run test with specific test file and method
-cargo test -p fory-tests --test $test_file $test_method
+cargo test -p tests --test $test_file $test_method
# run specific test under subdirectory
cargo test --test mod $dir$::$test_file::$test_method
# debug specific test under subdirectory and get backtrace
diff --git a/docs/guide/DEVELOPMENT.md b/docs/guide/DEVELOPMENT.md
index 921143aaa..8ac96d9cc 100644
--- a/docs/guide/DEVELOPMENT.md
+++ b/docs/guide/DEVELOPMENT.md
@@ -97,7 +97,7 @@ cargo build
# run test
cargo test
# run specific test
-cargo test -p fory-tests --test $test_file $test_method
+cargo test -p tests --test $test_file $test_method
# run specific test under subdirectory
cargo test --test mod $dir$::$test_file::$test_method
# debug specific test under subdirectory and get backtrace
diff --git a/rust/README.md b/rust/README.md
index 8f523b305..264c55cd4 100644
--- a/rust/README.md
+++ b/rust/README.md
@@ -969,7 +969,7 @@ Note: Static data types (non-dynamic types) are secure by
nature and not subject
- **Panic on error for backtraces**: Toggle `FORY_PANIC_ON_ERROR=1` (or
`true`) alongside `RUST_BACKTRACE=1` when running tests or binaries to panic at
the exact site an error is constructed. Reset the variable afterwards to avoid
aborting user-facing code paths.
- **Struct field tracing**: Add the `#[fory_debug]` attribute alongside
`#[derive(ForyObject)]` to tell the macro to emit hook invocations for that
type. Once compiled with debug hooks, call `set_before_write_field_func`,
`set_after_write_field_func`, `set_before_read_field_func`, or
`set_after_read_field_func` (from `fory-core/src/serializer/struct_.rs`) to
plug in custom callbacks, and use `reset_struct_debug_hooks()` when you want
the defaults back.
- **Lightweight logging**: Without custom hooks, enable
`ENABLE_FORY_DEBUG_OUTPUT=1` to print field-level read/write events emitted by
the default hook functions. This is especially useful when investigating
alignment or cursor mismatches.
-- **Test-time hygiene**: Some integration tests expect `FORY_PANIC_ON_ERROR`
to remain unset. Export it only for focused debugging sessions, and prefer
`cargo test --features tests -p fory-tests --test <case>` when isolating
failing scenarios.
+- **Test-time hygiene**: Some integration tests expect `FORY_PANIC_ON_ERROR`
to remain unset. Export it only for focused debugging sessions, and prefer
`cargo test --features tests -p tests --test <case>` when isolating failing
scenarios.
## 🛠️ Development
@@ -987,7 +987,7 @@ cargo build
cargo test --features tests
# Run specific test
-cargo test -p fory-tests --test test_complex_struct
+cargo test -p tests --test test_complex_struct
```
### Code Quality
diff --git a/rust/fory/src/lib.rs b/rust/fory/src/lib.rs
index b0b289aa1..778c94bbe 100644
--- a/rust/fory/src/lib.rs
+++ b/rust/fory/src/lib.rs
@@ -1081,7 +1081,7 @@
//! events. This is useful for spotting cursor misalignment or unexpected
buffer growth.
//! - **Test-time hygiene**: Some integration tests expect
`FORY_PANIC_ON_ERROR` to stay unset.
//! Export it only during focused debugging, and rely on targeted commands
such as
-//! `cargo test --features tests -p fory-tests --test <case>` when isolating
failures.
+//! `cargo test --features tests -p tests --test <case>` when isolating
failures.
//!
//! ## Documentation
//!
diff --git a/rust/tests/Cargo.toml b/rust/tests/Cargo.toml
index e7c218d7f..3f9ee2343 100644
--- a/rust/tests/Cargo.toml
+++ b/rust/tests/Cargo.toml
@@ -16,7 +16,7 @@
# under the License.
[package]
-name = "fory-tests"
+name = "tests"
version.workspace = true
edition.workspace = true
rust-version.workspace = true
diff --git a/rust/tests/tests/compatible/test_struct.rs
b/rust/tests/tests/compatible/test_struct.rs
index 105edb106..cf41c2f71 100644
--- a/rust/tests/tests/compatible/test_struct.rs
+++ b/rust/tests/tests/compatible/test_struct.rs
@@ -19,7 +19,7 @@ use fory_core::fory::Fory;
use fory_derive::ForyObject;
use std::collections::{HashMap, HashSet};
-// RUSTFLAGS="-Awarnings" cargo expand -p fory-tests --test test_struct
+// RUSTFLAGS="-Awarnings" cargo expand -p tests --test test_struct
#[test]
fn simple() {
#[derive(ForyObject, Debug)]
diff --git a/rust/tests/tests/test_complex_struct.rs
b/rust/tests/tests/test_complex_struct.rs
index accc593a7..0cb92de0e 100644
--- a/rust/tests/tests/test_complex_struct.rs
+++ b/rust/tests/tests/test_complex_struct.rs
@@ -21,7 +21,7 @@ use fory_derive::ForyObject;
use chrono::{DateTime, NaiveDate, NaiveDateTime};
use std::collections::HashMap;
-// RUSTFLAGS="-Awarnings" cargo expand -p fory-tests --test test_complex_struct
+// RUSTFLAGS="-Awarnings" cargo expand -p tests --test test_complex_struct
// #[test]
// fn any() {
// #[derive(ForyObject, Debug)]
diff --git a/rust/tests/tests/test_cross_language.rs
b/rust/tests/tests/test_cross_language.rs
index ffd571abb..9a61cc55c 100644
--- a/rust/tests/tests/test_cross_language.rs
+++ b/rust/tests/tests/test_cross_language.rs
@@ -27,7 +27,7 @@ use fory_derive::ForyObject;
use std::collections::{HashMap, HashSet};
use std::{fs, vec};
-// RUSTFLAGS="-Awarnings" cargo expand -p fory-tests --test test_cross_language
+// RUSTFLAGS="-Awarnings" cargo expand -p tests --test test_cross_language
fn get_data_file() -> String {
std::env::var("DATA_FILE").expect("DATA_FILE not set")
}
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]