Ejemplo n.º 1
0
 /**
  * @depends test_foundation_ui_create_files_directories
  * @depends test_foundation_ui_get_okcdesign_custom_directory_path
  */
 function test_foundation_ui_get_theme_scss_file_path()
 {
     $theme_test_directory = foundation_ui_get_okcdesign_custom_directory_path() . '/phpunit_test_' . rand();
     $path = foundation_ui_get_theme_scss_file_path($theme_test_directory);
     $this->assertContains(foundation_ui_get_okcdesign_custom_directory_path(), $path);
     rmdir($theme_test_directory);
 }
Ejemplo n.º 2
0
/**
 * Return scss string of user-defined scss for a specific theme.
 * @param $themename
 * @return string
 */
function foundation_ui_get_theme_custom_scss($themename)
{
    $scss = '';
    $filepath = foundation_ui_get_theme_scss_file_path($themename);
    if (file_exists($filepath)) {
        $scss = file_get_contents(foundation_ui_get_theme_scss_file_path($themename));
    }
    return $scss;
}