spring – Error in lambda expression in Java (Functional Programming)

I am new to functional programming. I used to use the enhanced for loop. But when trying to use forEach () using the lambda expression, I get a red marker.

I have a user class and address that has a user-to-address @OneToMany relationship.

public class User {

    private Long id;

   @OneToMany(mappedBy = "user")
    private List
addressList=new ArrayList<>(); //omitted all getters/setters/default constructer }


public class Address {

    private Long id;

    private User user;

   //omitted all getters/setters/default constructer

So, I am trying to insert data into the database using test cases that are:

package com.jpa.manytomany.manytomany;

import com.jpa.manytomany.manytomany.model.Address;
import com.jpa.manytomany.manytomany.model.Role;
import com.jpa.manytomany.manytomany.model.User;
import com.jpa.manytomany.manytomany.repository.AddressRepository;
import com.jpa.manytomany.manytomany.repository.RoleRepository;
import com.jpa.manytomany.manytomany.repository.UserRepository;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.test.context.junit4.SpringRunner;

import java.util.ArrayList;
import java.util.List;

public class ManytomanyApplicationTests {

    private Logger logger= LoggerFactory.getLogger(this.getClass());

    private UserRepository userRepository;

    private AddressRepository addressRepository;

    public void insert_user_and_address(){
        User user=userRepository.findById(1L);
       //user returned from db

        Address address1=new Address("Kapan");
        Address address2=new Address("chabail");
        Address address3=new Address("Suryabinayak");

addressList=new ArrayList<>(); addressList.add(address1); addressList.add(address2); addressList.add(address3); addressList.forEach(address -> address.setUser(user) addressRepository.insertAddress(address) ); } }

I tried to use the expression lamda using:

addressList.forEach(address ->

But the error shown by red is the one shown below in the image:

enter the description of the image here

enter the description of the image here