Skip to content

Commit

Permalink
remove txt from file name
Browse files Browse the repository at this point in the history
  • Loading branch information
smirnovaae committed Mar 11, 2024
1 parent 92343eb commit 5619e82
Show file tree
Hide file tree
Showing 6 changed files with 5 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ private AttributionDataShareConstants() {
public static final String FILE_PATH = "/tmp/";
public static final String REQ_FILE_NAME = "P.AB2D.NGD.REQ.";
public static final String REQ_FILE_NAME_PATTERN = "'D'yyMMdd.'T'hhmmsss";
public static final String REQ_FILE_FORMAT = ".OUT.txt";
public static final String REQ_FILE_FORMAT = ".OUT";

public static final String FIRST_LINE = "HDR_BENEDATAREQ_";
public static final String LAST_LINE = "TLR_BENEDATAREQ_";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
public class AttributionDataShareHandler implements RequestStreamHandler {

// Writes out a file to the FILE_PATH.
// I.E: "P.AB2D.NGD.REQ.D240209.T1122001.OUT.txt"
// I.E: "P.AB2D.NGD.REQ.D240209.T1122001.OUT"

public void handleRequest(InputStream inputStream, OutputStream outputStream, Context context) throws IOException {
LambdaLogger logger = context.getLogger();
Expand Down
4 changes: 2 additions & 2 deletions optout/src/main/java/gov/cms/ab2d/optout/OptOutConstants.java
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ public class OptOutConstants {
public static final String ACCESS_TOKEN = "dev/TestLambdaToken";
public static final String ENDPOINT = "https://s3.amazonaws.com";
public static final String TEST_ENDPOINT = "http://127.0.0.1:8001";
public static final String TEST_FILE_NAME = "P#EFT.ON.NGD.AB2D.RSP.D240123.T1122001.txt";
public static final String TEST_FILE_NAME = "optOutDummy.txt";
public static final String BFD_S3_BUCKET_NAME = "ab2d-opt-out-temp-349849222861-us-east-1";
public static final Region S3_REGION = Region.US_EAST_1;
public static final String HEADER_RESP = "HDR_BENEDATARSP";
Expand All @@ -25,7 +25,7 @@ public class OptOutConstants {
public static final String LINE_SEPARATOR = System.getProperty("line.separator");
public static final String CONF_FILE_NAME = "P.AB2D.NGD.CONF.";
public static final String CONF_FILE_NAME_PATTERN = "'D'yyMMdd.'T'hhmmsss";
public static final String CONF_FILE_FORMAT = ".OUT.txt";
public static final String CONF_FILE_FORMAT = ".OUT";
public static final String UPDATE_STATEMENT = "UPDATE public.coverage\n" +
"SET opt_out_flag = ?, effective_date = current_timestamp\n" +
"WHERE current_mbi = ? OR historic_mbis LIKE CONCAT( '%',?,'%')";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ public class OptOutHandlerTest {
@BeforeAll
static void beforeAll() throws URISyntaxException {
when(sqsEvent.getRecords()).thenReturn(Collections.singletonList(sqsMessage));
when(sqsMessage.getBody()).thenReturn("P#EFT.ON.NGD.AB2D.RSP.D240123.T1122001.txt");
when(sqsMessage.getBody()).thenReturn("optOutDummy.txt");
when(handler.processorInit(anyString(), any(LambdaLogger.class))).thenReturn(OPT_OUT_PROCESSOR);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,6 @@ void afterEach() {
}

@Test

void processTest(){
optOutProcessing.isRejected = false;
optOutProcessing.process();
Expand Down
File renamed without changes.

0 comments on commit 5619e82

Please sign in to comment.