message: One more test for def capture
  Summary: For better night sleep.
diff: @@ -97,7 +97,7 @@ f(1)(2)(3) == 6",
  }
  #[test]
  -fn test_lambda_capture() {
  +fn test_lambda_capture_from_module() {
  assert::is_true(
  "
  f = lambda y: x + y
  @@ -105,6 +105,10 @@ x = 100
  f(42) == 142
  ",
  );
  +}
  +
  +#[test]
  +fn test_lambda_capture_from_def() {
  assert::is_true(
  "
  def inside():
  @@ -116,6 +120,20 @@ inside()
  );
  }
  +#[test]
  +fn test_lambda_capture_reassigned_from_def() {
  + assert::is_true(
  + "
  +def inside():
  + x = 100
  + f = lambda y: x + y
  + x = 200
  + return f(42) == 242
  +inside()
  +",
  + );
  +}
  +
  #[test]
  fn test_def_freeze() {
  let mut a = Assert::new();
  