diff --git a/ProcessLib/SmallDeformation/SmallDeformationFEM.h b/ProcessLib/SmallDeformation/SmallDeformationFEM.h
index d9a56cd479265fd88a805af1a7d5a3172be09543..35d47752f6033db9c13728aada04723afaabf6de 100644
--- a/ProcessLib/SmallDeformation/SmallDeformationFEM.h
+++ b/ProcessLib/SmallDeformation/SmallDeformationFEM.h
@@ -265,11 +265,6 @@ public:
 
         auto const& b = _process_data.specific_body_force;
 
-        double const T_ref =
-            _process_data.reference_temperature
-                ? (*_process_data.reference_temperature)(t, x_position)[0]
-                : std::numeric_limits<double>::quiet_NaN();
-
         for (unsigned ip = 0; ip < n_integration_points; ip++)
         {
             x_position.setIntegrationPoint(ip);
@@ -319,6 +314,12 @@ public:
                 .emplace<
                     MathLib::KelvinVector::KelvinVectorType<DisplacementDim>>(
                     eps_prev);
+
+            double const T_ref =
+                _process_data.reference_temperature
+                    ? (*_process_data.reference_temperature)(t, x_position)[0]
+                    : std::numeric_limits<double>::quiet_NaN();
+
             variables_prev[static_cast<int>(MPL::Variable::temperature)]
                 .emplace<double>(T_ref);
             variables[static_cast<int>(MPL::Variable::mechanical_strain)]
diff --git a/Tests/Data/Mechanics/Linear/MFront/cube_1e0_orthotropic_xyz.prj b/Tests/Data/Mechanics/Linear/MFront/cube_1e0_orthotropic_xyz.prj
index f255fdead091a06dbfbb00006eeb8d43251f6ea0..eaeb84496fe0f3707ab860b11ae18e636d9e17e6 100644
--- a/Tests/Data/Mechanics/Linear/MFront/cube_1e0_orthotropic_xyz.prj
+++ b/Tests/Data/Mechanics/Linear/MFront/cube_1e0_orthotropic_xyz.prj
@@ -24,7 +24,7 @@
             </constitutive_relation>
             <solid_density>rho_sr</solid_density>
             <specific_body_force>0 0 0</specific_body_force>
-            <reference_temperature>293.15</reference_temperature>
+            <reference_temperature>T_ref</reference_temperature>
             <process_variables>
                 <process_variable>displacement</process_variable>
             </process_variables>
@@ -82,6 +82,11 @@
         <basis_vector_2>e2</basis_vector_2>
     </local_coordinate_system>
     <parameters>
+        <parameter>
+            <name>T_ref</name>
+            <type>Constant</type>
+            <values>293.15</values>
+        </parameter>
         <parameter>
             <name>e0</name>
             <type>Constant</type>
diff --git a/Tests/Data/Mechanics/Linear/MFront/cube_1e0_orthotropic_yzx.prj b/Tests/Data/Mechanics/Linear/MFront/cube_1e0_orthotropic_yzx.prj
index f0c194bf2dd2f550a43893ac6630dcef01372b4c..df77b546b65f9ebf071d41e4349f663bcbaeb1ba 100644
--- a/Tests/Data/Mechanics/Linear/MFront/cube_1e0_orthotropic_yzx.prj
+++ b/Tests/Data/Mechanics/Linear/MFront/cube_1e0_orthotropic_yzx.prj
@@ -24,7 +24,7 @@
             </constitutive_relation>
             <solid_density>rho_sr</solid_density>
             <specific_body_force>0 0 0</specific_body_force>
-            <reference_temperature>293.15</reference_temperature>
+            <reference_temperature>T_ref</reference_temperature>
             <process_variables>
                 <process_variable>displacement</process_variable>
             </process_variables>
@@ -82,6 +82,11 @@
         <basis_vector_2>e0</basis_vector_2>
     </local_coordinate_system>
     <parameters>
+        <parameter>
+            <name>T_ref</name>
+            <type>Constant</type>
+            <values>293.15</values>
+        </parameter>
         <parameter>
             <name>e0</name>
             <type>Constant</type>
diff --git a/Tests/Data/Mechanics/Linear/MFront/cube_1e0_orthotropic_zxy.prj b/Tests/Data/Mechanics/Linear/MFront/cube_1e0_orthotropic_zxy.prj
index fee768e852a2fcc2d4f7b52d7fde30e20042c735..fbd6a4d38ea96a7eb59168ea6044d905e9837162 100644
--- a/Tests/Data/Mechanics/Linear/MFront/cube_1e0_orthotropic_zxy.prj
+++ b/Tests/Data/Mechanics/Linear/MFront/cube_1e0_orthotropic_zxy.prj
@@ -24,7 +24,7 @@
             </constitutive_relation>
             <solid_density>rho_sr</solid_density>
             <specific_body_force>0 0 0</specific_body_force>
-            <reference_temperature>293.15</reference_temperature>
+            <reference_temperature>T_ref</reference_temperature>
             <process_variables>
                 <process_variable>displacement</process_variable>
             </process_variables>
@@ -82,6 +82,11 @@
         <basis_vector_2>e1</basis_vector_2>
     </local_coordinate_system>
     <parameters>
+        <parameter>
+            <name>T_ref</name>
+            <type>Constant</type>
+            <values>293.15</values>
+        </parameter>
         <parameter>
             <name>e0</name>
             <type>Constant</type>
diff --git a/Tests/Data/Mechanics/Linear/MFront/cube_standard_elasticity_brick.prj b/Tests/Data/Mechanics/Linear/MFront/cube_standard_elasticity_brick.prj
index 0e5882cddc7a0c5fcef854fadb0cf2038322fdb4..5d19f15b60fc867e06b79dc9f04b0d4cdb629f14 100644
--- a/Tests/Data/Mechanics/Linear/MFront/cube_standard_elasticity_brick.prj
+++ b/Tests/Data/Mechanics/Linear/MFront/cube_standard_elasticity_brick.prj
@@ -17,7 +17,7 @@
             </constitutive_relation>
             <solid_density>rho_sr</solid_density>
             <specific_body_force>0 0 0</specific_body_force>
-            <reference_temperature>293.15</reference_temperature>
+            <reference_temperature>T_ref</reference_temperature>
             <process_variables>
                 <process_variable>displacement</process_variable>
             </process_variables>
@@ -68,6 +68,11 @@
         </output>
     </time_loop>
     <parameters>
+        <parameter>
+            <name>T_ref</name>
+            <type>Constant</type>
+            <values>293.15</values>
+        </parameter>
         <parameter>
             <name>E</name>
             <type>Constant</type>
diff --git a/Tests/Data/Mechanics/Linear/MFront/square_1e0_orthotropic_45xy_z.prj b/Tests/Data/Mechanics/Linear/MFront/square_1e0_orthotropic_45xy_z.prj
index c706c916b94cfe03f1232d121ccee66cdd794b98..402a2c51abc6dd8d4804b27220ca6beb42f3e18a 100644
--- a/Tests/Data/Mechanics/Linear/MFront/square_1e0_orthotropic_45xy_z.prj
+++ b/Tests/Data/Mechanics/Linear/MFront/square_1e0_orthotropic_45xy_z.prj
@@ -22,7 +22,7 @@
             </constitutive_relation>
             <solid_density>rho_sr</solid_density>
             <specific_body_force>0 0</specific_body_force>
-            <reference_temperature>293.15</reference_temperature>
+            <reference_temperature>T_ref</reference_temperature>
             <process_variables>
                 <process_variable>displacement</process_variable>
             </process_variables>
@@ -79,6 +79,11 @@
         <basis_vector_1>e1</basis_vector_1>
     </local_coordinate_system>
     <parameters>
+        <parameter>
+            <name>T_ref</name>
+            <type>Constant</type>
+            <values>293.15</values>
+        </parameter>
         <parameter>
             <name>e0</name>
             <type>Constant</type>
diff --git a/Tests/Data/Mechanics/Linear/MFront/square_1e0_orthotropic_xyz.prj b/Tests/Data/Mechanics/Linear/MFront/square_1e0_orthotropic_xyz.prj
index 3df7b14847ffdac995171d72a5e07f63b12731d4..b0daf22fd4c880e0724c98a2de45a363513bf0f1 100644
--- a/Tests/Data/Mechanics/Linear/MFront/square_1e0_orthotropic_xyz.prj
+++ b/Tests/Data/Mechanics/Linear/MFront/square_1e0_orthotropic_xyz.prj
@@ -22,7 +22,7 @@
             </constitutive_relation>
             <solid_density>rho_sr</solid_density>
             <specific_body_force>0 0</specific_body_force>
-            <reference_temperature>293.15</reference_temperature>
+            <reference_temperature>T_ref</reference_temperature>
             <process_variables>
                 <process_variable>displacement</process_variable>
             </process_variables>
@@ -79,6 +79,11 @@
         <basis_vector_1>e1</basis_vector_1>
     </local_coordinate_system>
     <parameters>
+        <parameter>
+            <name>T_ref</name>
+            <type>Constant</type>
+            <values>293.15</values>
+        </parameter>
         <parameter>
             <name>e0</name>
             <type>Constant</type>
diff --git a/Tests/Data/Mechanics/Linear/MFront/square_1e0_orthotropic_y-xz.prj b/Tests/Data/Mechanics/Linear/MFront/square_1e0_orthotropic_y-xz.prj
index c86c6150adb756ed50e342e8ea905704ecc4ebd7..361dcfb3da37cc12ad063604bafe5e39858015b9 100644
--- a/Tests/Data/Mechanics/Linear/MFront/square_1e0_orthotropic_y-xz.prj
+++ b/Tests/Data/Mechanics/Linear/MFront/square_1e0_orthotropic_y-xz.prj
@@ -22,7 +22,7 @@
             </constitutive_relation>
             <solid_density>rho_sr</solid_density>
             <specific_body_force>0 0</specific_body_force>
-            <reference_temperature>293.15</reference_temperature>
+            <reference_temperature>T_ref</reference_temperature>
             <process_variables>
                 <process_variable>displacement</process_variable>
             </process_variables>
@@ -79,6 +79,11 @@
         <basis_vector_1>e0_negative</basis_vector_1>
     </local_coordinate_system>
     <parameters>
+        <parameter>
+            <name>T_ref</name>
+            <type>Constant</type>
+            <values>293.15</values>
+        </parameter>
         <parameter>
             <name>e0_negative</name>
             <type>Constant</type>