Auto-sync from website-creator
This commit is contained in:
170
TESTING_GUIDE_UPDATED.md
Normal file
170
TESTING_GUIDE_UPDATED.md
Normal file
@@ -0,0 +1,170 @@
|
||||
# 🧪 SEO Skills - Complete Testing Guide (Updated)
|
||||
|
||||
**Purpose:** Test all implemented features systematically
|
||||
**Updated:** 2026-03-08 - Direct write mode (no git required)
|
||||
|
||||
---
|
||||
|
||||
## ✅ UPDATED: Test 5.1 - Auto-Publish (Direct Write, No Git!)
|
||||
|
||||
### **Test 5.1: Direct Write to Website Folder (DEFAULT)**
|
||||
|
||||
```bash
|
||||
cd /Users/kunthawatgreethong/Gitea/opencode-skill/skills/seo-multi-channel/scripts
|
||||
|
||||
# Create test blog post
|
||||
cat > /tmp/test-blog.md << 'EOF'
|
||||
---
|
||||
title: "คู่มือ Podcast Hosting ที่ดีที่สุด 2026"
|
||||
description: "เปรียบเทียบบริการ podcast hosting ทั้งหมด"
|
||||
keywords: ["podcast hosting", "บริการ podcast"]
|
||||
slug: podcast-hosting-best-2026
|
||||
lang: th
|
||||
category: guides
|
||||
created: 2026-03-08
|
||||
---
|
||||
|
||||
# คู่มือ Podcast Hosting ที่ดีที่สุด 2026
|
||||
|
||||
บทความนี้จะเปรียบเทียบแพลตฟอร์มยอดนิยม...
|
||||
EOF
|
||||
|
||||
# Create a test website structure
|
||||
mkdir -p /tmp/my-website/src/content/blog/\(th\)
|
||||
mkdir -p /tmp/my-website/public/images/blog
|
||||
|
||||
# Publish (DIRECT WRITE - no git needed!)
|
||||
python3 auto_publish.py \
|
||||
--file /tmp/test-blog.md \
|
||||
--website-repo /tmp/my-website
|
||||
```
|
||||
|
||||
**Expected Output:**
|
||||
```
|
||||
📝 Publishing to Astro
|
||||
|
||||
✓ Saved: /tmp/my-website/src/content/blog/(th)/podcast-hosting-best-2026.md
|
||||
✓ Direct write complete (no git)
|
||||
|
||||
✅ Published successfully!
|
||||
Slug: podcast-hosting-best-2026
|
||||
Language: th
|
||||
Path: /tmp/my-website/src/content/blog/(th)/podcast-hosting-best-2026.md
|
||||
Method: direct_write
|
||||
```
|
||||
|
||||
**Verify:**
|
||||
- [ ] Markdown file saved in correct language folder `(th)`
|
||||
- [ ] File contains all frontmatter
|
||||
- [ ] No git required - direct file write!
|
||||
|
||||
---
|
||||
|
||||
### **Test 5.2: English Blog Post**
|
||||
|
||||
```bash
|
||||
cat > /tmp/test-blog-en.md << 'EOF'
|
||||
---
|
||||
title: "Best Podcast Hosting 2026"
|
||||
description: "Compare all podcast hosting services"
|
||||
slug: best-podcast-hosting-2026
|
||||
lang: en
|
||||
---
|
||||
|
||||
# Best Podcast Hosting 2026
|
||||
|
||||
This article compares...
|
||||
EOF
|
||||
|
||||
# Publish to same website
|
||||
python3 auto_publish.py \
|
||||
--file /tmp/test-blog-en.md \
|
||||
--website-repo /tmp/my-website
|
||||
```
|
||||
|
||||
**Expected:**
|
||||
- [ ] Saved in `(en)` folder
|
||||
- [ ] `src/content/blog/(en)/best-podcast-hosting-2026.md`
|
||||
|
||||
---
|
||||
|
||||
### **Test 5.3: With Images**
|
||||
|
||||
```bash
|
||||
# If you have images from image generation
|
||||
python3 auto_publish.py \
|
||||
--file /tmp/test-blog.md \
|
||||
--website-repo /tmp/my-website \
|
||||
--image ./output/podcast-hosting/facebook/images/generated_xxx.png
|
||||
```
|
||||
|
||||
**Expected:**
|
||||
- [ ] Images copied to `public/images/blog/podcast-hosting-best-2026/`
|
||||
- [ ] Blog post references images correctly
|
||||
|
||||
---
|
||||
|
||||
### **Optional: Git Mode (If You Want Gitea Integration)**
|
||||
|
||||
```bash
|
||||
# Only if you want git commit/push to Gitea
|
||||
python3 auto_publish.py \
|
||||
--file /tmp/test-blog.md \
|
||||
--website-repo /tmp/my-website \
|
||||
--use-git
|
||||
```
|
||||
|
||||
**This is OPTIONAL - default is direct write (no git needed)**
|
||||
|
||||
---
|
||||
|
||||
## 📝 UPDATED TEST CHECKLIST
|
||||
|
||||
### **Group 5: Auto-Publish (Direct Write)**
|
||||
|
||||
- [ ] **Test 5.1:** Thai blog post (direct write)
|
||||
- [ ] **Test 5.2:** English blog post (direct write)
|
||||
- [ ] **Test 5.3:** With images
|
||||
- [ ] **Optional Test 5.4:** With git (if using Gitea)
|
||||
|
||||
**Credentials needed:** NONE!
|
||||
**Git needed:** NO! (default is direct write)
|
||||
|
||||
---
|
||||
|
||||
## 🔧 HOW IT WORKS NOW
|
||||
|
||||
### **Default Mode (Direct Write):**
|
||||
```
|
||||
Website Repo: /path/to/my-website/
|
||||
↓
|
||||
src/content/blog/(th)/ → Thai articles
|
||||
src/content/blog/(en)/ → English articles
|
||||
public/images/blog/ → Article images
|
||||
```
|
||||
|
||||
**No git, no Gitea, no commits - just direct file write!**
|
||||
|
||||
### **Optional Git Mode:**
|
||||
```
|
||||
Only if you use --use-git flag:
|
||||
1. Writes file (same as above)
|
||||
2. Git add .
|
||||
3. Git commit -m "Add blog post: xxx"
|
||||
4. Git push to Gitea
|
||||
5. Triggers auto-deploy
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
## ✅ ALL TESTS UPDATED
|
||||
|
||||
The testing guide has been updated. All auto-publish tests now:
|
||||
- ✅ Use **direct write** by default (no git)
|
||||
- ✅ Work with **Gitea repos** (just point to folder)
|
||||
- ✅ **No git credentials** needed
|
||||
- ✅ **Optional --use-git** flag if you want Gitea integration
|
||||
|
||||
---
|
||||
|
||||
**Ready to test! No git setup required - just point to your website folder.** 🎯
|
||||
Reference in New Issue
Block a user