webhook增加type参数:同步自测代码

This commit is contained in:
wanjia 2023-03-30 14:03:12 +08:00
parent cfb8a3b89d
commit 016dc6f8e9
2 changed files with 3 additions and 3 deletions

View File

@ -57,7 +57,7 @@ public class GitLinkApiTest {
@Test
public void addWebhook() throws JsonProcessingException {
webhooks = new Webhook(true, "json", "GET", "123456", "http://localhost:10000", "*", new Object[]{"push"});
webhooks = new Webhook(true, "json", "GET", "123456", "http://localhost:10000", "*", new Object[]{"push"}, "softbot");
Object[] params = new Object[]{"xxq250", "ruoyi-vue-pro"};
Response response = api.addWebhook(85175,params,webhooks);
System.out.println(response.getData());
@ -65,7 +65,7 @@ public class GitLinkApiTest {
@Test
public void updateWebhook() throws JsonProcessingException {
webhooks = new Webhook(false, "json", "GET", "123456", "http://localhost:10000", "*", new Object[]{"push"});
webhooks = new Webhook(false, "json", "GET", "123456", "http://localhost:10000", "*", new Object[]{"push"}, "softbot");
Object[] params = new Object[]{"xxq250", "ruoyi-vue-pro"};
Response response = api.updateWebhook(85175,params,1082,webhooks);
System.out.println(response.getData());

View File

@ -38,7 +38,7 @@ class RestTemplateUtilTests {
@BeforeEach
public void setUp() {
mapper = new ObjectMapper();
webhooks = new Webhook(true, "json", "GET", "123456", "http://localhost:10000", "*", new Object[]{"push"});
webhooks = new Webhook(true, "json", "GET", "123456", "http://localhost:10000", "*", new Object[]{"push"}, "softbot");
headParams = new HashMap<>();
headParams.put("Authorization", "Bearer "+TOKEN);
}