Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-58682

Strange failure in memcached tests

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Done
    • Affects Version/s: 3.2.2, 3.3
    • Fix Version/s: 3.3
    • Component/s: Caching, Unit tests
    • Labels:
    • Affected Branches:
      MOODLE_32_STABLE, MOODLE_33_STABLE
    • Fixed Branches:
      MOODLE_33_STABLE

      Description

      To reproduce:

      • Have a memcached instance (or multiple) running.
      • Set it for testing:

        define('TEST_CACHESTORE_MEMCACHED_TESTSERVERS', '127.0.0.1:11211');
        

      • Run vendor/bin/phpunit cachestore_memcached_test cache/stores/memcached/tests/memcached_test.php.
      • Expected: Pass
      • Got:

        Moodle 3.3beta (Build: 20170421), faedb2736eca0008750721c806e81d4d256d43dc
        Php: 5.6.30, pgsql: 9.3.16, OS: Darwin 16.5.0 x86_64
        PHPUnit 5.5.7 by Sebastian Bergmann and contributors.
         
        .S.F.                                                               5 / 5 (100%)
         
        Time: 1.54 seconds, Memory: 54.00MB
         
        There was 1 failure:
         
        1) cachestore_memcached_test::test_dedicated_cache
        Failed asserting that false is true.
         
        /Users/stronk7/git_moodle/integration/cache/stores/memcached/tests/memcached_test.php:348
        /Users/stronk7/git_moodle/integration/lib/phpunit/classes/advanced_testcase.php:80
         
        To re-run:
         vendor/bin/phpunit cachestore_memcached_test cache/stores/memcached/tests/memcached_test.php
         
        FAILURES!
        Tests: 5, Assertions: 174, Failures: 1, Skipped: 1.
        

      Note I commented about that failure in another channel in March (https://pastebin.com/bptbdQ9E) so this is not new. The question is... is it only me, or is it global and we don't have memcached enable elsewhere?

      Also interesting... if I disable test_multi_use_compatibility (by renaming it to "notest---) then the failure above does not happen and test_dedicated_cache passes. So something weird is happening.

      Using memcached 1.4.34 here, for the records.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                mudrd8mz David Mudrák (@mudrd8mz)
                Reporter:
                stronk7 Eloy Lafuente (stronk7)
                Participants:
                Component watchers:
                Matteo Scaramuccia, Amaia Anabitarte, Carlos Escobedo, Ferran Recio, Sara Arjona (@sarjona), Víctor Déniz Falcón, Andrew Nicols, Jun Pataleta, Michael Hawkins, Shamim Rezaie, Simey Lameze
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Fix Release Date:
                  15/May/17