### Question:
ComposerPathUtils { public static String buildProviderPath(final Context context) { TokenMatcher.State state = context.getAttributes().require(TokenMatcher.State.class); Map<String, String> tokens = state.getTokens(); return buildProviderPath(tokens.get(VENDOR_TOKEN), tokens.get(PROJECT_TOKEN)); } private  ComposerPathUtils(); static String getVendorToken(final Context context); static String getProjectToken(final Context context); static String getVersionToken(final Context context); static String buildZipballPath(final Context context); static String buildZipballPath(final String vendor, final String project, final String version); static String buildProviderPath(final Context context); static String buildProviderPath(final String vendor, final String project);  }### Answer:
@Test public void buildProviderPathFromTokens() { when(context.getAttributes()).thenReturn(contextAttributes); when(contextAttributes.require(TokenMatcher.State.class)).thenReturn(state); when(state.getTokens()).thenReturn(tokens); when(tokens.get(VENDOR_TOKEN)).thenReturn("testvendor"); when(tokens.get(PROJECT_TOKEN)).thenReturn("testproject"); assertThat(ComposerPathUtils.buildProviderPath(context), is("p/testvendor/testproject.json")); }
@Test public void buildProviderPathFromValues() { assertThat(ComposerPathUtils.buildProviderPath("testvendor", "testproject"), is("p/testvendor/testproject.json")); }