33import static org .assertj .core .api .Assertions .assertThat ;
44import static org .junit .jupiter .api .Assertions .assertThrows ;
55
6+ import com .retailsvc .http .internal .LegacyRequestAccess ;
67import com .retailsvc .http .internal .RequestContext ;
78import java .util .Map ;
89import java .util .NoSuchElementException ;
@@ -21,13 +22,13 @@ void readsBoundContext() throws Exception {
2122 AtomicReference <String > seenOpId = new AtomicReference <>();
2223 AtomicReference <Map <String , String >> seenPathParams = new AtomicReference <>();
2324
24- ScopedValue .where (Request .CONTEXT , ctx )
25+ ScopedValue .where (LegacyRequestAccess .CONTEXT , ctx )
2526 .call (
2627 () -> {
27- seenBytes .set (Request .bytes ());
28- seenParsed .set (Request .parsed ());
29- seenOpId .set (Request .operationId ());
30- seenPathParams .set (Request .pathParams ());
28+ seenBytes .set (LegacyRequestAccess .bytes ());
29+ seenParsed .set (LegacyRequestAccess .parsed ());
30+ seenOpId .set (LegacyRequestAccess .operationId ());
31+ seenPathParams .set (LegacyRequestAccess .pathParams ());
3132 return null ;
3233 });
3334
@@ -39,6 +40,6 @@ void readsBoundContext() throws Exception {
3940
4041 @ Test
4142 void readingOutsideScopeThrows () {
42- assertThrows (NoSuchElementException .class , Request ::bytes );
43+ assertThrows (NoSuchElementException .class , LegacyRequestAccess ::bytes );
4344 }
4445}
0 commit comments