Skip to content

Commit 301a668

Browse files
authored
Add test confirming that login works without contact obj URI (#2983)
This is a follow-up to PR #2954.
1 parent 2dd7cee commit 301a668

1 file changed

Lines changed: 11 additions & 1 deletion

File tree

core/src/test/java/google/registry/flows/session/LoginFlowTestCase.java

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,7 @@ void testFailure_invalidContactObjectUri() {
133133
}
134134

135135
@Test
136-
void testSuccess_contactObjectUri_worksWhenNotProhibited() throws Exception {
136+
void testSuccess_contactObjectUriSent_worksWhenNotProhibited() throws Exception {
137137
persistResource(
138138
FeatureFlag.get(PROHIBIT_CONTACT_OBJECTS_ON_LOGIN)
139139
.asBuilder()
@@ -142,6 +142,16 @@ void testSuccess_contactObjectUri_worksWhenNotProhibited() throws Exception {
142142
doSuccessfulTest("login_with_contact_objuri.xml");
143143
}
144144

145+
@Test
146+
void testSuccess_contactObjectUriNotSent_worksWhenNotProhibited() throws Exception {
147+
persistResource(
148+
FeatureFlag.get(PROHIBIT_CONTACT_OBJECTS_ON_LOGIN)
149+
.asBuilder()
150+
.setStatusMap(ImmutableSortedMap.of(START_OF_TIME, FeatureStatus.INACTIVE))
151+
.build());
152+
doSuccessfulTest("login_valid.xml");
153+
}
154+
145155
@Test
146156
void testFailure_invalidTypes() {
147157
doFailingTest("login_invalid_types.xml", UnimplementedObjectServiceException.class);

0 commit comments

Comments
 (0)