mirror of
https://github.com/gfx-rs/wgpu.git
synced 2025-12-08 21:26:17 +00:00
Make sure all doctests and tests in wgpu-types run
This commit is contained in:
parent
eaa87ba42c
commit
9670e9e6b9
2
.github/workflows/ci.yml
vendored
2
.github/workflows/ci.yml
vendored
@ -336,7 +336,7 @@ jobs:
|
||||
run: |
|
||||
set -e
|
||||
|
||||
cargo test --doc
|
||||
cargo test --doc -p wgpu -p wgpu-core -p wgpu-hal -p wgpu-types
|
||||
|
||||
fmt:
|
||||
name: Format
|
||||
|
||||
@ -13,7 +13,7 @@ members = [
|
||||
"run-wasm"
|
||||
]
|
||||
exclude = []
|
||||
default-members = ["wgpu", "wgpu-hal", "wgpu-info"]
|
||||
default-members = ["wgpu", "wgpu-hal", "wgpu-info", "wgpu-types"]
|
||||
|
||||
[workspace.package]
|
||||
edition = "2021"
|
||||
|
||||
@ -81,7 +81,7 @@ This allows us to compose the operations to form the various kinds of tracker me
|
||||
that need to happen in the codebase. For each resource in the given merger, the following
|
||||
operation applies:
|
||||
|
||||
```
|
||||
```text
|
||||
UsageScope <- Resource = insert(scope, usage) OR merge(scope, usage)
|
||||
UsageScope <- UsageScope = insert(scope, scope) OR merge(scope, scope)
|
||||
CommandBuffer <- UsageScope = insert(buffer.start, buffer.end, scope)
|
||||
|
||||
@ -25,4 +25,5 @@ bitflags = "1"
|
||||
serde = { version = "1", features = ["serde_derive"], optional = true }
|
||||
|
||||
[dev-dependencies]
|
||||
serde = { version = "1", features = ["serde_derive"] }
|
||||
serde_json = "1.0.85"
|
||||
|
||||
@ -9,7 +9,7 @@
|
||||
)]
|
||||
#![warn(missing_docs, unsafe_op_in_unsafe_fn)]
|
||||
|
||||
#[cfg(feature = "serde")]
|
||||
#[cfg(any(feature = "serde", test))]
|
||||
use serde::{Deserialize, Serialize};
|
||||
use std::hash::{Hash, Hasher};
|
||||
use std::{num::NonZeroU32, ops::Range};
|
||||
@ -2103,7 +2103,7 @@ pub enum TextureFormat {
|
||||
},
|
||||
}
|
||||
|
||||
#[cfg(feature = "serde")]
|
||||
#[cfg(any(feature = "serde", test))]
|
||||
impl<'de> Deserialize<'de> for TextureFormat {
|
||||
fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>
|
||||
where
|
||||
@ -2239,7 +2239,7 @@ impl<'de> Deserialize<'de> for TextureFormat {
|
||||
}
|
||||
}
|
||||
|
||||
#[cfg(feature = "serde")]
|
||||
#[cfg(any(feature = "serde", test))]
|
||||
impl Serialize for TextureFormat {
|
||||
fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
|
||||
where
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user