diff --git a/Cargo.toml b/Cargo.toml
index 27e2f4b..4a466f3 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -94,102 +94,127 @@ path = "src/lib.rs"
 [[test]]
 name = "regression"
 path = "tests/regression.rs"
+required-features = ["parsing", "full", "extra-traits"]
 
 [[test]]
 name = "test_asyncness"
 path = "tests/test_asyncness.rs"
+required-features = ["full", "derive"]
 
 [[test]]
 name = "test_attribute"
 path = "tests/test_attribute.rs"
+required-features = ["full", "derive"]
 
 [[test]]
 name = "test_derive_input"
 path = "tests/test_derive_input.rs"
+required-features = ["full", "extra-traits", "derive"]
 
 [[test]]
 name = "test_expr"
 path = "tests/test_expr.rs"
+required-features = ["full", "extra-traits", "derive"]
 
 [[test]]
 name = "test_generics"
 path = "tests/test_generics.rs"
+required-features = ["full", "derive"]
 
 [[test]]
 name = "test_grouping"
 path = "tests/test_grouping.rs"
+required-features = ["full", "derive"]
 
 [[test]]
 name = "test_ident"
 path = "tests/test_ident.rs"
+required-features = ["parsing"]
 
 [[test]]
 name = "test_item"
 path = "tests/test_item.rs"
+required-features = ["full", "derive"]
 
 [[test]]
 name = "test_iterators"
 path = "tests/test_iterators.rs"
+required-features = ["full", "derive"]
 
 [[test]]
 name = "test_lit"
 path = "tests/test_lit.rs"
+required-features = ["full", "extra-traits", "derive"]
 
 [[test]]
 name = "test_meta"
 path = "tests/test_meta.rs"
+required-features = ["full", "extra-traits", "derive"]
 
 [[test]]
 name = "test_parse_buffer"
 path = "tests/test_parse_buffer.rs"
+required-features = ["parsing"]
 
 [[test]]
 name = "test_parse_quote"
 path = "tests/test_parse_quote.rs"
+required-features = ["parsing"]
 
 [[test]]
 name = "test_parse_stream"
 path = "tests/test_parse_stream.rs"
+required-features = ["parsing"]
 
 [[test]]
 name = "test_pat"
 path = "tests/test_pat.rs"
+required-features = ["full", "extra-traits", "derive"]
 
 [[test]]
 name = "test_path"
 path = "tests/test_path.rs"
+required-features = ["full", "derive"]
 
 [[test]]
 name = "test_receiver"
 path = "tests/test_receiver.rs"
+required-features = ["full", "derive"]
 
 [[test]]
 name = "test_shebang"
 path = "tests/test_shebang.rs"
+required-features = ["full", "derive"]
 
 [[test]]
 name = "test_size"
 path = "tests/test_size.rs"
+required-features = ["full"]
 
 [[test]]
 name = "test_stmt"
 path = "tests/test_stmt.rs"
+required-features = ["full", "derive"]
 
 [[test]]
 name = "test_token_trees"
 path = "tests/test_token_trees.rs"
+required-features = ["full", "derive"]
 
 [[test]]
 name = "test_ty"
 path = "tests/test_ty.rs"
+required-features = ["full", "extra-traits", "derive"]
 
 [[test]]
 name = "test_unparenthesize"
 path = "tests/test_unparenthesize.rs"
+required-features = ["full", "visit-mut", "parsing", "derive"]
 
 [[test]]
 name = "test_visibility"
 path = "tests/test_visibility.rs"
+required-features = ["full", "extra-traits", "derive"]
 
 [[test]]
 name = "zzz_stable"
diff --git a/src/custom_keyword.rs b/src/custom_keyword.rs
index cc4f632..e9b76d5 100644
--- a/src/custom_keyword.rs
+++ b/src/custom_keyword.rs
@@ -43,7 +43,7 @@
 /// identifier that is not a keyword, these can be declared as custom keywords
 /// by crates that need to use them as such.
 ///
-/// ```
+/// ```ignore
 /// use syn::{LitBool, LitStr, Result, Token};
 /// use syn::parse::{Parse, ParseStream};
 ///
diff --git a/src/custom_punctuation.rs b/src/custom_punctuation.rs
index eef5f54..c0ea04a 100644
--- a/src/custom_punctuation.rs
+++ b/src/custom_punctuation.rs
@@ -29,7 +29,7 @@
 ///
 /// # Example
 ///
-/// ```
+/// ```ignore
 /// use proc_macro2::{TokenStream, TokenTree};
 /// use syn::parse::{Parse, ParseStream, Peek, Result};
 /// use syn::punctuated::Punctuated;
diff --git a/src/error.rs b/src/error.rs
index 6331054..0c92a40 100644
--- a/src/error.rs
+++ b/src/error.rs
@@ -29,7 +29,7 @@ pub type Result<T> = std::result::Result<T, Error>;
 ///
 /// [`parse_macro_input!`]: crate::parse_macro_input!
 ///
-/// ```
+/// ```ignore
 /// # extern crate proc_macro;
 /// #
 /// use proc_macro::TokenStream;
@@ -70,7 +70,7 @@ pub type Result<T> = std::result::Result<T, Error>;
 /// [`.to_compile_error()`]: Error::to_compile_error
 /// [`.into_compile_error()`]: Error::into_compile_error
 ///
-/// ```
+/// ```ignore
 /// # extern crate proc_macro;
 /// #
 /// # use proc_macro::TokenStream;
@@ -136,7 +136,7 @@ impl Error {
     ///
     /// # Example
     ///
-    /// ```
+    /// ```ignore
     /// use syn::{Error, Ident, LitStr, Result, Token};
     /// use syn::parse::ParseStream;
     ///
@@ -235,7 +235,7 @@ impl Error {
     ///
     /// # Example
     ///
-    /// ```
+    /// ```ignore
     /// # extern crate proc_macro;
     /// #
     /// use proc_macro::TokenStream;
diff --git a/src/lib.rs b/src/lib.rs
index 1d2ccc3..884488d 100644
--- a/src/lib.rs
+++ b/src/lib.rs
@@ -69,7 +69,7 @@
 //! proc-macro = true
 //! ```
 //!
-//! ```
+//! ```ignore
 //! # extern crate proc_macro;
 //! #
 //! use proc_macro::TokenStream;
diff --git a/src/lit.rs b/src/lit.rs
index 45c26d5..0d844a6 100644
--- a/src/lit.rs
+++ b/src/lit.rs
@@ -438,7 +438,7 @@ impl LitInt {
     /// resulting errors will be correctly spanned to point to the literal token
     /// in the macro input.
     ///
-    /// ```
+    /// ```ignore
     /// use syn::LitInt;
     /// use syn::parse::{Parse, ParseStream, Result};
     ///
diff --git a/src/punctuated.rs b/src/punctuated.rs
index ebaaa94..b7c037f 100644
--- a/src/punctuated.rs
+++ b/src/punctuated.rs
@@ -990,7 +990,7 @@ impl<T, P> Pair<T, P> {
     ///
     /// # Example
     ///
-    /// ```
+    /// ```ignore
     /// # use proc_macro2::Span;
     /// # use syn::punctuated::Punctuated;
     /// # use syn::{parse_quote, Token, TypeParamBound};
diff --git a/src/token.rs b/src/token.rs
index 752c188..9a4216b 100644
--- a/src/token.rs
+++ b/src/token.rs
@@ -12,7 +12,7 @@
 //!
 //! [`ItemStatic`]: crate::ItemStatic
 //!
-//! ```
+//! ```ignore
 //! # use syn::{Attribute, Expr, Ident, Token, Type, Visibility};
 //! #
 //! pub struct ItemStatic {
@@ -40,7 +40,7 @@
 //! [`bracketed!`]: crate::bracketed!
 //! [`braced!`]: crate::braced!
 //!
-//! ```
+//! ```ignore
 //! use syn::{Attribute, Result};
 //! use syn::parse::{Parse, ParseStream};
 //! #
@@ -806,7 +806,7 @@ define_delimiters! {
 /// As a type, `Token!` is commonly used in the type of struct fields, the type
 /// of a `let` statement, or in turbofish for a `parse` function.
 ///
-/// ```
+/// ```ignore
 /// use syn::{Ident, Token};
 /// use syn::parse::{Parse, ParseStream, Result};
 ///
@@ -830,7 +830,7 @@ define_delimiters! {
 /// As an expression, `Token!` is used for peeking tokens or instantiating
 /// tokens from a span.
 ///
-/// ```
+/// ```ignore
 /// # use syn::{Ident, Token};
 /// # use syn::parse::{Parse, ParseStream, Result};
 /// #
diff --git a/tests/debug/gen.rs b/tests/debug/gen.rs
index d766a8e..8612e07 100644
--- a/tests/debug/gen.rs
+++ b/tests/debug/gen.rs
@@ -1,3 +1,4 @@
+#![cfg(any(feature = "full", feature = "derive"))]
 // This file is @generated by syn-internal-codegen.
 // It is not intended for manual editing.
 
