<?php

namespace Langchecker;

use Transvision\Json;
LangManager::$error_checking = false;
DotLangParser::$extract_metadata = false;
DotLangParser::$log_errors = false;
$untranslated = [];
$translated = [];
$file_count = [];
$all_strings = [];
foreach ($mozilla as $current_locale) {
    // Initialize locale
    $untranslated[$current_locale] = 0;
    $translated[$current_locale] = 0;
    $file_count[$current_locale] = 0;
    foreach (Project::getWebsitesByDataType($sites, 'lang') as $current_website) {
        $reference_locale = Project::getReferenceLocale($current_website);
        // Ignore reference language
        if ($current_locale == $reference_locale) {
            continue;
        }
        foreach (Project::getWebsiteFiles($current_website) as $current_filename) {
            // File not supported
            if (!Project::isSupportedLocale($current_website, $current_locale, $current_filename, $langfiles_subsets)) {
                continue;
            }
            // File marked as obsolete
            if (Project::isObsoleteFile($current_website, $current_filename, $current_locale)) {
                continue;
Exemplo n.º 2
0
 public function testGetFileMissing()
 {
     $obj = new _DotLangParser();
     _DotLangParser::$log_errors = false;
     $this->boolean($obj->getFile('fakefile', false))->isFalse();
 }