|
| 1 | +import type { TestPattern } from "../e2e.test"; |
| 2 | +import { ANSWER_YES, CREATE_KINTONE_PLUGIN_COMMAND } from "../utils/constants"; |
| 3 | +import { getBoundMessage } from "../../src/messages"; |
| 4 | + |
| 5 | +const m = getBoundMessage("en"); |
| 6 | + |
| 7 | +export const pattern: TestPattern = { |
| 8 | + description: |
| 9 | + "#JsSdkTest-14 Should able to create plugin with `create-kintone-plugin` command and all options", |
| 10 | + input: { |
| 11 | + command: CREATE_KINTONE_PLUGIN_COMMAND, |
| 12 | + outputDir: "test14", |
| 13 | + questionsInput: [ |
| 14 | + { |
| 15 | + question: m("Q_NameEn"), |
| 16 | + answer: "test14-name", |
| 17 | + }, |
| 18 | + { |
| 19 | + question: m("Q_DescriptionEn"), |
| 20 | + answer: "test14-description", |
| 21 | + }, |
| 22 | + { |
| 23 | + question: m("Q_SupportJa"), |
| 24 | + answer: ANSWER_YES, |
| 25 | + }, |
| 26 | + { |
| 27 | + question: m("Q_NameJa"), |
| 28 | + answer: "私のプラグイン", |
| 29 | + }, |
| 30 | + { |
| 31 | + question: m("Q_DescriptionJa"), |
| 32 | + answer: "私のプラグイン", |
| 33 | + }, |
| 34 | + { |
| 35 | + question: m("Q_SupportZh"), |
| 36 | + answer: ANSWER_YES, |
| 37 | + }, |
| 38 | + { |
| 39 | + question: m("Q_NameZh"), |
| 40 | + answer: "我的插件", |
| 41 | + }, |
| 42 | + { |
| 43 | + question: m("Q_DescriptionZh"), |
| 44 | + answer: "我的插件", |
| 45 | + }, |
| 46 | + { |
| 47 | + question: m("Q_WebsiteUrlEn"), |
| 48 | + answer: "https://github.com", |
| 49 | + }, |
| 50 | + { |
| 51 | + question: m("Q_WebsiteUrlJa"), |
| 52 | + answer: "https://github.jp", |
| 53 | + }, |
| 54 | + { |
| 55 | + question: m("Q_WebsiteUrlZh"), |
| 56 | + answer: "https://github.cn", |
| 57 | + }, |
| 58 | + { |
| 59 | + question: m("Q_MobileSupport"), |
| 60 | + answer: ANSWER_YES, |
| 61 | + }, |
| 62 | + { |
| 63 | + question: m("Q_EnablePluginUploader"), |
| 64 | + answer: ANSWER_YES, |
| 65 | + }, |
| 66 | + ], |
| 67 | + }, |
| 68 | + expected: { |
| 69 | + success: { |
| 70 | + manifestJson: { |
| 71 | + name: { |
| 72 | + en: "test14-name", |
| 73 | + ja: "私のプラグイン", |
| 74 | + zh: "我的插件", |
| 75 | + }, |
| 76 | + description: { |
| 77 | + en: "test14-description", |
| 78 | + ja: "私のプラグイン", |
| 79 | + zh: "我的插件", |
| 80 | + }, |
| 81 | + homepage_url: { |
| 82 | + en: "https://github.com", |
| 83 | + ja: "https://github.jp", |
| 84 | + zh: "https://github.cn", |
| 85 | + }, |
| 86 | + mobile: { |
| 87 | + js: ["js/mobile.js"], |
| 88 | + css: ["css/mobile.css"], |
| 89 | + }, |
| 90 | + }, |
| 91 | + }, |
| 92 | + }, |
| 93 | +}; |
0 commit comments