Projet

Général

Profil

Révision 1e39edcb

Ajouté par Assos Assos il y a plus de 7 ans

Weekly update of contrib modules

Voir les différences:

drupal7/sites/all/modules/ctools/tests/context.test
5 5
    return array(
6 6
      'name' => 'Keywords substitution',
7 7
      'description' => 'Verify that keywords are properly replaced with data.',
8
      'group' => 'Chaos Tools Suite',
8
      'group' => 'ctools',
9 9
    );
10 10
  }
11 11

  
......
51 51
        "%{$node->title}",
52 52
        t('Keyword after escaped and unescaped percent sign has been replaced.'),
53 53
      ),
54
      '%%foo:bar' => array(
55
        "%foo:bar",
56
        t('Non-existant context ignored.'),
57
      ),
58
      'There was about 20%-30% difference in price.' => array(
59
        'There was about 20%-30% difference in price.',
60
        t('Non-keyword percent sign left untouched.'),
61
      ),
62
      'href="my%20file%2dname.pdf"' => array(
63
        'href="my%20file%2dname.pdf"',
64
        t('HTTP URL escape left untouched.'),
65
      ),
66
      'href="my%a0file%fdname.pdf"' => array(
67
        'href="my%a0file%fdname.pdf"',
68
        t('HTTP URL escape (high-chars) left untouched.'),
69
      ),
70
      '<a href="http://www.example.com/here%20is%20a%20pdf.pdf">Click here!</a>' => array(
71
        '<a href="http://www.example.com/here%20is%20a%20pdf.pdf">Click here!</a>',
72
        t('HTTP URL escape percent sign left untouched in HTML.'),
73
      ),
74
      'SELECT * FROM {table} WHERE field = "%s"' => array(
75
        'SELECT * FROM {table} WHERE field = "%s"',
76
        t('SQL percent sign left untouched.'),
77
      ),
54 78
    );
55 79
    foreach ($checks as $string => $expectations) {
56 80
      list($expected_result, $message) = $expectations;

Formats disponibles : Unified diff