private static void doTestSamzaPropertyAccessWithPhysicalStream(String propertyName, String value,
      SamzaPropertyAssertion assertion) {
    // streams.<streamId>.<property>
    assertion.doAssertion(new StreamConfig(new MapConfig(ImmutableMap.of(
        String.format(StreamConfig.STREAM_ID_PREFIX, STREAM_ID) + propertyName, value,
        // all streams need to have a system
        JobConfig.JOB_DEFAULT_SYSTEM, SYSTEM,
        // map the stream id to the physical stream
        String.format(StreamConfig.PHYSICAL_NAME_FOR_STREAM_ID, STREAM_ID), PHYSICAL_STREAM))),
        SYSTEM_STREAM_PHYSICAL);

    // systems.<system>.streams.<stream>.<property> with a specific system for the stream id
    assertion.doAssertion(new StreamConfig(new MapConfig(ImmutableMap.of(
        String.format(StreamConfig.STREAM_PREFIX, SYSTEM, PHYSICAL_STREAM) + propertyName, value,
        // specify the system for the stream id
        String.format(StreamConfig.SYSTEM_FOR_STREAM_ID, STREAM_ID), SYSTEM,
        // map the stream id to the physical stream
        String.format(StreamConfig.PHYSICAL_NAME_FOR_STREAM_ID, STREAM_ID), PHYSICAL_STREAM))),
        SYSTEM_STREAM_PHYSICAL);

    // systems.<system>.streams.<stream>.<property> with system coming from job default system
    assertion.doAssertion(new StreamConfig(new MapConfig(ImmutableMap.of(
        String.format(StreamConfig.STREAM_PREFIX, SYSTEM, PHYSICAL_STREAM) + propertyName, value,
        // use job default system to get the system
        JobConfig.JOB_DEFAULT_SYSTEM, SYSTEM,
        // map the stream id to the physical stream
        String.format(StreamConfig.PHYSICAL_NAME_FOR_STREAM_ID, STREAM_ID), PHYSICAL_STREAM))),
        SYSTEM_STREAM_PHYSICAL);

    // systems.<system>.default.stream.<property>
    assertion.doAssertion(new StreamConfig(new MapConfig(ImmutableMap.of(
        String.format(SystemConfig.SYSTEM_DEFAULT_STREAMS_PREFIX_FORMAT, SYSTEM) + propertyName, value,
        // specify the system for the stream id
        String.format(StreamConfig.SYSTEM_FOR_STREAM_ID, STREAM_ID), SYSTEM,
        // map the stream id to the physical stream
        String.format(StreamConfig.PHYSICAL_NAME_FOR_STREAM_ID, STREAM_ID), PHYSICAL_STREAM))),
        SYSTEM_STREAM_PHYSICAL);
  }
Tests for Samza property access using different lookup methods, when using physical stream in system stream.
samza-core/src/test/java/org/apache/samza/config/TestStreamConfig.java