@VisibleForTesting
  static Row getRowConfig(ManagedConfig config, Schema transformSchema) {
    // May return an empty row (perhaps the underlying transform doesn't have any required
    // parameters)
    String yamlConfig = config.resolveUnderlyingConfig();
    Map<String, Object> configMap = YamlUtils.yamlStringToMap(yamlConfig);

    // The config Row object will be used to build the underlying SchemaTransform.
    // If a mapping for the SchemaTransform exists, we use it to update parameter names and align
    // with the underlying config schema
    Map<String, String> mapping = MAPPINGS.get(config.getTransformIdentifier());
    if (mapping != null && configMap != null) {
      Map<String, Object> remappedConfig = new HashMap<>();
      for (Map.Entry<String, Object> entry : configMap.entrySet()) {
        String paramName = entry.getKey();
        if (mapping.containsKey(paramName)) {
          paramName = mapping.get(paramName);
        }
        remappedConfig.put(paramName, entry.getValue());
      }
      configMap = remappedConfig;
    }

    return YamlUtils.toBeamRow(configMap, transformSchema, false);
  }
@Test
  public void testGetConfigRowFromYamlFile() throws URISyntaxException {
    String yamlConfigPath =
        Paths.get(getClass().getClassLoader().getResource("test_config.yaml").toURI())
            .toFile()
            .getAbsolutePath();
    ManagedConfig config =
        ManagedConfig.builder()
            .setTransformIdentifier(TestSchemaTransformProvider.IDENTIFIER)
            .setConfigUrl(yamlConfigPath)
            .build();
    Schema configSchema = new TestSchemaTransformProvider().configurationSchema();
    Row expectedRow =
        Row.withSchema(configSchema)
            .withFieldValue("extra_string", "abc")
            .withFieldValue("extra_integer", 123)
            .build();
    Row configRow =
        ManagedSchemaTransformProvider.getRowConfig(
            config, new TestSchemaTransformProvider().configurationSchema());

    assertEquals(expectedRow, configRow);
  }