From: Vásáry Dániel Date: Fri, 3 Nov 2023 20:00:57 +0000 (+0100) Subject: XLS import logic updated, test file normalized X-Git-Url: http://git.useribm.hu/?a=commitdiff_plain;h=3527f2f68623d21721da8f86db0184c7d1b66d64;p=mediacube.git XLS import logic updated, test file normalized --- diff --git a/mc-vod-sync/mc-vod-sync-app/src/test/java/hu/user/mcvodsync/BrightCoveClientIT.java b/mc-vod-sync/mc-vod-sync-app/src/test/java/hu/user/mcvodsync/BrightCoveClientIT.java index 54cc4eb3..4bc34606 100644 --- a/mc-vod-sync/mc-vod-sync-app/src/test/java/hu/user/mcvodsync/BrightCoveClientIT.java +++ b/mc-vod-sync/mc-vod-sync-app/src/test/java/hu/user/mcvodsync/BrightCoveClientIT.java @@ -1,6 +1,8 @@ package hu.user.mcvodsync; +import com.brightcove.cms.client.model.CreateVideoRequestBodyFields; import com.brightcove.cms.client.model.Playlist; +import com.brightcove.cms.client.model.Video; import hu.user.mcvodsync.brightcove.BrightCoveClient; import lombok.extern.log4j.Log4j2; import org.junit.Test; @@ -14,8 +16,6 @@ import org.springframework.test.context.junit4.SpringRunner; import java.util.List; -import static org.junit.Assert.assertNotNull; - @Log4j2 @RunWith(SpringRunner.class) @ComponentScan("hu.user.mcvodsync") @@ -23,21 +23,15 @@ import static org.junit.Assert.assertNotNull; @ActiveProfiles("dev") @TestPropertySource("classpath:application-dev.yaml") public class BrightCoveClientIT { + @Autowired private BrightCoveClient bcClient; - @Test - public void testOAuth() { - String authToken = bcClient.createToken(); - log.info("Token created {}", authToken); - assertNotNull(authToken); - } @Test public void testGetPlayLists() { - String authToken = bcClient.createToken(); try { - List playLists = bcClient.getPlayLists(authToken, 0, 10); + List playLists = bcClient.getPlayLists(0, 10); playLists.forEach(playList -> { log.info(playList.getName()); @@ -48,4 +42,76 @@ public class BrightCoveClientIT { } } + @Test + public void testGetVideos() { + try { + List