From c1bf962181adb3c59dab984c13eab304a171f7a4 Mon Sep 17 00:00:00 2001 From: Ji Sun Date: Fri, 1 Nov 2019 13:21:50 -0700 Subject: [PATCH] SDC-12760. upgrade.test_pipelines_upgrade.test_pipeline_upgrade[pipeline_full_path=/root/tests/upgrade/pipelines/sdc_1.6.0.0/Source_Destination/sdc_1.6.0.0_pipeline_Source_Destination.json] failing on Bifocals Change-Id: I021eb6d79965dfd372795b4b051128826488dd21 Reviewed-on: https://review.streamsets.net/c/datacollector/+/27223 Tested-by: StreamSets CI Reviewed-by: Junwei Yu --- .../destination/localfilesystem/LocalFileSystemDTarget.java | 2 +- .../src/main/resources/upgrader/LocalFileSystemDTarget.yaml | 2 +- .../localfilesystem/TestLocalFileSystemTargetUpgrader.java | 6 +++--- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/basic-lib/src/main/java/com/streamsets/pipeline/stage/destination/localfilesystem/LocalFileSystemDTarget.java b/basic-lib/src/main/java/com/streamsets/pipeline/stage/destination/localfilesystem/LocalFileSystemDTarget.java index bbab1daa9db..7f73b3dc450 100644 --- a/basic-lib/src/main/java/com/streamsets/pipeline/stage/destination/localfilesystem/LocalFileSystemDTarget.java +++ b/basic-lib/src/main/java/com/streamsets/pipeline/stage/destination/localfilesystem/LocalFileSystemDTarget.java @@ -26,7 +26,7 @@ import com.streamsets.pipeline.stage.destination.hdfs.HdfsTarget; @StageDef( - version = 3, + version = 4, label = "Local FS", description = "Writes to the local file system", icon = "localfilesystem.png", diff --git a/basic-lib/src/main/resources/upgrader/LocalFileSystemDTarget.yaml b/basic-lib/src/main/resources/upgrader/LocalFileSystemDTarget.yaml index 0579fc16dd9..ef85fa2ffd5 100644 --- a/basic-lib/src/main/resources/upgrader/LocalFileSystemDTarget.yaml +++ b/basic-lib/src/main/resources/upgrader/LocalFileSystemDTarget.yaml @@ -17,7 +17,7 @@ upgraderVersion: 1 upgrades: - - toVersion: 3 + - toVersion: 4 actions: - setConfig: name: configs.dataGeneratorFormatConfig.basicAuthUserInfo diff --git a/basic-lib/src/test/java/com/streamsets/pipeline/stage/destination/localfilesystem/TestLocalFileSystemTargetUpgrader.java b/basic-lib/src/test/java/com/streamsets/pipeline/stage/destination/localfilesystem/TestLocalFileSystemTargetUpgrader.java index 71745e16c8a..728aa2f7a2a 100644 --- a/basic-lib/src/test/java/com/streamsets/pipeline/stage/destination/localfilesystem/TestLocalFileSystemTargetUpgrader.java +++ b/basic-lib/src/test/java/com/streamsets/pipeline/stage/destination/localfilesystem/TestLocalFileSystemTargetUpgrader.java @@ -28,7 +28,7 @@ public class TestLocalFileSystemTargetUpgrader { @Test - public void testV2ToV3() { + public void testV3ToV4() { List configs = new ArrayList<>(); final URL yamlResource = ClassLoader.getSystemClassLoader().getResource("upgrader/LocalFileSystemDTarget.yaml"); @@ -39,8 +39,8 @@ public void testV2ToV3() { ); StageUpgrader.Context context = Mockito.mock(StageUpgrader.Context.class); - Mockito.doReturn(2).when(context).getFromVersion(); - Mockito.doReturn(3).when(context).getToVersion(); + Mockito.doReturn(3).when(context).getFromVersion(); + Mockito.doReturn(4).when(context).getToVersion(); configs = upgrader.upgrade(configs, context);