From a7bbd6d13eb0c88976a1f75e63f9c9813e2828b7 Mon Sep 17 00:00:00 2001 From: Dries Buytaert Date: Sat, 26 Jun 2010 02:16:23 +0000 Subject: - Patch #808534 by dhthwy, Damien Tournoud, chx: file_get_file_references() is completely broken. --- modules/simpletest/tests/entity_query.test | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) (limited to 'modules/simpletest') diff --git a/modules/simpletest/tests/entity_query.test b/modules/simpletest/tests/entity_query.test index 359e6fb93..0b3db8b59 100644 --- a/modules/simpletest/tests/entity_query.test +++ b/modules/simpletest/tests/entity_query.test @@ -248,6 +248,23 @@ class EntityFieldQueryTestCase extends DrupalWebTestCase { array('test_entity', 101), ), t('Test revision age.')); + // Test that fields attached to the non-revision supporting entity + // 'test_entity_bundle_key' are reachable in FIELD_LOAD_REVISION. + $query = new EntityFieldQuery(); + $query + ->fieldCondition($this->fields[0], 'value', 100, '<') + ->age(FIELD_LOAD_REVISION); + $this->assertEntityFieldQuery($query, array( + array('test_entity_bundle_key', 1), + array('test_entity_bundle_key', 2), + array('test_entity_bundle_key', 3), + array('test_entity_bundle_key', 4), + array('test_entity', 1), + array('test_entity', 2), + array('test_entity', 3), + array('test_entity', 4), + ), t('Test that fields are reachable from FIELD_LOAD_REVISION even for non-revision entities.')); + // Test entity sort by entity_id. $query = new EntityFieldQuery(); $query -- cgit v1.2.3