Align RuntimeHintsPredicates with new FieldMode

Closes gh-29063
This commit is contained in:
Brian Clozel
2022-09-02 18:15:50 +02:00
parent 4368e2563f
commit 7ace1f9dc5
6 changed files with 33 additions and 10 deletions

View File

@@ -87,7 +87,7 @@ class InjectionCodeGeneratorTests {
TestBean bean = new TestBean();
Field field = ReflectionUtils.findField(bean.getClass(), "age");
this.generator.generateInjectionCode(field, INSTANCE_VARIABLE, CodeBlock.of("$L", 123));
assertThat(RuntimeHintsPredicates.reflection().onField(TestBean.class, "age").allowWrite())
assertThat(RuntimeHintsPredicates.reflection().onField(TestBean.class, "age").withWriteMode())
.accepts(this.hints);
}