Add unit tests for PDF Packager converter functionality
- Implement tests for converter properties, ensuring correct input and output formats. - Add tests for chip parsing, covering various image, pdf_image, and pdfa chip formats. - Include tests for the isArchiveOutput and getOutputFileName functions. - Mock execFile for testing the convert function, verifying command execution and output file creation. - Ensure all chips are parseable and validate the completeness of chip categories.
This commit is contained in:
parent
87bd318303
commit
944fe18b75
11 changed files with 2233 additions and 8 deletions
|
|
@ -150,6 +150,37 @@ environment:
|
|||
|
||||
---
|
||||
|
||||
## 📝 PDF Packager 設定
|
||||
|
||||
### PDF 數位簽章
|
||||
|
||||
PDF Packager 預設**開箱即用**,Docker 建置時已自動產生預設憑證。如需使用自訂憑證,可透過以下環境變數配置:
|
||||
|
||||
| 變數 | 預設值 | 說明 |
|
||||
| ----------------------- | -------------------------- | ------------------- |
|
||||
| `PDF_SIGN_P12_PATH` | `/app/certs/default.p12` | PKCS12 憑證檔案路徑 |
|
||||
| `PDF_SIGN_P12_PASSWORD` | (空) | 憑證密碼 |
|
||||
| `PDF_SIGN_REASON` | `ConvertX-CN PDF Packager` | 簽章原因 |
|
||||
| `PDF_SIGN_LOCATION` | `Taiwan` | 簽章地點 |
|
||||
| `PDF_SIGN_CONTACT` | `convertx-cn@localhost` | 聯絡資訊 |
|
||||
|
||||
**使用自訂憑證範例**:
|
||||
|
||||
```yaml
|
||||
environment:
|
||||
- PDF_SIGN_P12_PATH=/app/certs/company.p12
|
||||
- PDF_SIGN_P12_PASSWORD=your_password
|
||||
- PDF_SIGN_REASON=文件已核准
|
||||
- PDF_SIGN_LOCATION=台北
|
||||
- PDF_SIGN_CONTACT=admin@company.com
|
||||
volumes:
|
||||
- /path/to/certs:/app/certs:ro
|
||||
```
|
||||
|
||||
詳細說明請參考 [PDF Packager 說明](功能說明/PDF-Packager.md)。
|
||||
|
||||
---
|
||||
|
||||
## 相關文件
|
||||
|
||||
- [Docker 部署指南](部署指南/Docker部署.md)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue