diff --git a/generators/bootstrap-application/__snapshots__/generator.spec.js.snap b/generators/bootstrap-application/__snapshots__/generator.spec.js.snap index 018e57f43..7b39f65f3 100644 --- a/generators/bootstrap-application/__snapshots__/generator.spec.js.snap +++ b/generators/bootstrap-application/__snapshots__/generator.spec.js.snap @@ -22,7 +22,7 @@ exports[`SubGenerator bootstrap-application of dotnetcore JHipster blueprint > r "blueprints": [ { "name": "generator-jhipster-dotnetcore", - "version": "4.0.0", + "version": "4.1.0", }, ], "buildTool": "maven", diff --git a/generators/dotnetcore/templates/dotnetcore/test/Project.Test/Controllers/_persistClass_ControllerIntTest.cs.ejs b/generators/dotnetcore/templates/dotnetcore/test/Project.Test/Controllers/_persistClass_ControllerIntTest.cs.ejs index 45597f3aa..39c61bb55 100644 --- a/generators/dotnetcore/templates/dotnetcore/test/Project.Test/Controllers/_persistClass_ControllerIntTest.cs.ejs +++ b/generators/dotnetcore/templates/dotnetcore/test/Project.Test/Controllers/_persistClass_ControllerIntTest.cs.ejs @@ -330,8 +330,8 @@ namespace <%= namespace %>.Test.Controllers { var databaseSizeBeforeTest = await _<%= camelCasedEntityClass %>Repository.CountAsync(); - // Set the field to null - _<%= camelCasedEntityClass %>.<%= field.fieldNamePascalized %> = null; + // Set the field to default + _<%= camelCasedEntityClass %>.<%= field.fieldNamePascalized %> = default; // Create the <%= pascalizedEntityClass %>, which fails. <%_ if (hasDto) { _%>