Skip to content

Commit

Permalink
Updates
Browse files Browse the repository at this point in the history
  • Loading branch information
cansavvy committed Jul 1, 2024
1 parent 3d043d2 commit caae3e3
Show file tree
Hide file tree
Showing 2 changed files with 61 additions and 9 deletions.
52 changes: 52 additions & 0 deletions tests/testthat/test-misc.R
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
### Any functions that aren't tested somewhere else are tested here.
# Functions here should be listed in alphabetical order

test_that("Example Test", {
# Code that runs the thing here
# Some logic here that tests the output
})
# convert_coursera_quizzes() Convert Leanpub md quiz to Coursera yaml quiz

# convert_quiz() Convert Leanpub md quiz to Coursera yaml quiz

# course_path() Find main course git directory

# course_to_book_txt() Create Book.txt file from files existing in quiz directory

# render_without_toc() Create TOC-less course website for use in Coursera or Leanpub

# extract_meta() Extract meta fields from a tag

# extract_object_id() Extract Object IDs using Google Slides API

# get_chapters() Make Leanpub file that has embed webpage of a chapter

# get_gs_pptx() Download Google Slides pptx file

# get_object_id_notes() Retrieve Speaker Notes and their corresponding Object (Slide) IDs from a Google Slides presentation

# get_slide_id() Get Slide ID from URL

# get_yaml_spec() Load in yaml specifications from _bookdown.yml or _quarto.yml

# gs_id_from_slide() get_image_link_from_slide() get_image_from_slide() Google Slides Helper Functions

# gs_png_url() get_slide_page() gs_png_download() include_slide() Get Google Slide PNG URL

# make_embed_markdown() Make Leanpub file that has embed webpage of a chapter

# output_destination() Declare file path to docs/ folder

# parse_q_tag() Parse apart a tag

# parse_quiz() extract_quiz() Parse Quiz and Other Checking Functions

# parse_quiz_df() Parse quiz into a data.frame

# pptx_notes() pptx_slide_text_df() pptx_slide_note_df() unzip_pptx() Get Notes from a PowerPoint (usually from Google Slides)

# qrmd_files() Get file paths to all qmds or rmds in the course website directory

# set_knitr_image_path() Set image path for knitr

# xml_notes() Get Notes from XML
18 changes: 9 additions & 9 deletions tests/testthat/test-rmd_leanpub_prep.R
Original file line number Diff line number Diff line change
Expand Up @@ -19,15 +19,15 @@ test_that("Create Leanpub IFrames for Rmd", {
# 2. Is the file 'resources/chapt_screen_images/chapter_urls.tsv' made fresh?
# 2. Does chapter_urls.tsv file made have columns with information that are labeled "url", "chapt_title" and "img_path"

set_up_leanpub(
make_book_txt = TRUE,
quiz_dir = NULL
)

website_to_embed_leanpub(
chapt_img_key = 'resources/chapt_screen_images/chapter_urls.tsv',
make_book_txt = TRUE,
quiz_dir = NULL)
#set_up_leanpub(
# make_book_txt = TRUE,
# quiz_dir = NULL
#)

#website_to_embed_leanpub(
#chapt_img_key = 'resources/chapt_screen_images/chapter_urls.tsv',
#make_book_txt = TRUE,
#quiz_dir = NULL)

## TEST HERE:
# 1. Did each chapter get a md in the manuscript folder?
Expand Down

0 comments on commit caae3e3

Please sign in to comment.