This PR sets up the new integrated test/bench suite. It then migrates all benchmarks and some related tests to the new suite. There's also some documentation and some linting. For now, a lot of the old tests are left alone so this PR doesn't become even larger than it already is. Eventually, all tests should be migrated to the new suite though so there isn't a confusing mix of two systems.
111 lines
1.6 KiB
Text
111 lines
1.6 KiB
Text
import Lean
|
||
/-!
|
||
# Tests for the `#where` command
|
||
-/
|
||
|
||
-- Restore the options to a pristine state
|
||
set_option internal.cmdlineSnapshots false
|
||
set_option printMessageEndPos false
|
||
set_option Elab.inServer false
|
||
|
||
/-- info: -- In root namespace with initial scope -/
|
||
#guard_msgs in #where
|
||
|
||
noncomputable section
|
||
/-- info: noncomputable section -/
|
||
#guard_msgs in #where
|
||
end
|
||
|
||
namespace WhereTest
|
||
variable (x : Nat) (α : Type)
|
||
/--
|
||
info: namespace WhereTest
|
||
|
||
variable (x : Nat) (α : Type)
|
||
-/
|
||
#guard_msgs in #where
|
||
|
||
universe u v
|
||
universe w
|
||
|
||
/--
|
||
info: namespace WhereTest
|
||
|
||
universe u v w
|
||
|
||
variable (x : Nat) (α : Type)
|
||
-/
|
||
#guard_msgs in #where
|
||
|
||
set_option pp.piBinderTypes false
|
||
|
||
/--
|
||
info: namespace WhereTest
|
||
|
||
universe u v w
|
||
|
||
variable (x : Nat) (α : Type)
|
||
|
||
set_option pp.piBinderTypes false
|
||
-/
|
||
#guard_msgs in #where
|
||
|
||
include x
|
||
|
||
/--
|
||
info: namespace WhereTest
|
||
|
||
universe u v w
|
||
|
||
variable (x : Nat) (α : Type)
|
||
|
||
include x
|
||
|
||
set_option pp.piBinderTypes false
|
||
-/
|
||
#guard_msgs in #where
|
||
|
||
end WhereTest
|
||
|
||
section
|
||
open Lean Meta
|
||
|
||
/--
|
||
info: open Lean Lean.Meta
|
||
-/
|
||
#guard_msgs in #where
|
||
|
||
open Elab hiding TermElabM
|
||
|
||
/--
|
||
info: open Lean Lean.Meta
|
||
open Lean.Elab hiding TermElabM
|
||
-/
|
||
#guard_msgs in #where
|
||
|
||
open Command Std
|
||
open Array renaming map -> listMap
|
||
|
||
/--
|
||
info: open Lean Lean.Meta
|
||
open Lean.Elab hiding TermElabM
|
||
open Lean.Elab.Command Std
|
||
open Array renaming map → listMap
|
||
-/
|
||
#guard_msgs in #where
|
||
end
|
||
|
||
|
||
/-!
|
||
Stripping comments on `variable` binders
|
||
-/
|
||
section
|
||
variable (a : Nat)
|
||
-- Some discussion
|
||
(b : Nat)
|
||
-- Some more discussion
|
||
|
||
/-- info: variable (a : Nat) (b : Nat) -/
|
||
#guard_msgs in #where
|
||
|
||
end
|