@@ 7939-7953 (lines=15) @@ | ||
7936 | * |
|
7937 | * @return void |
|
7938 | */ |
|
7939 | public function testNotInArrayWithOneValue() { |
|
7940 | $this->loadFixtures('Article'); |
|
7941 | $Article = new Article(); |
|
7942 | $Article->recursive = -1; |
|
7943 | ||
7944 | $result = $Article->find( |
|
7945 | 'all', |
|
7946 | array( |
|
7947 | 'conditions' => array( |
|
7948 | 'Article.id NOT' => array(1) |
|
7949 | ) |
|
7950 | ) |
|
7951 | ); |
|
7952 | $this->assertTrue(is_array($result) && !empty($result)); |
|
7953 | } |
|
7954 | ||
7955 | /** |
|
7956 | * test to assert that != in key together with a single element array will work |
|
@@ 7960-7974 (lines=15) @@ | ||
7957 | * |
|
7958 | * @return void |
|
7959 | */ |
|
7960 | public function testNotEqualsInArrayWithOneValue() { |
|
7961 | $this->loadFixtures('Article'); |
|
7962 | $Article = new Article(); |
|
7963 | $Article->recursive = -1; |
|
7964 | ||
7965 | $result = $Article->find( |
|
7966 | 'all', |
|
7967 | array( |
|
7968 | 'conditions' => array( |
|
7969 | 'Article.id !=' => array(1) |
|
7970 | ) |
|
7971 | ) |
|
7972 | ); |
|
7973 | $this->assertTrue(is_array($result) && !empty($result)); |
|
7974 | } |
|
7975 | ||
7976 | /** |
|
7977 | * test custom find method |