Permalink
Browse files

Adding stub datasource to test_app.

  • Loading branch information...
1 parent ed74653 commit 0c0e5d111b42ceb648b7edc17ff81dc6ec539ce5 @jperras jperras committed Sep 24, 2009
Showing with 30 additions and 0 deletions.
  1. +30 −0 cake/tests/test_app/models/datasources/test_source.php
View
30 cake/tests/test_app/models/datasources/test_source.php
@@ -0,0 +1,30 @@
+<?php
+
+class TestSource extends DataSource {
+
+ function describe($model) {
+ return compact('model');
+ }
+
+ function listSources() {
+ return array('test_source');
+ }
+
+ function create($model, $fields = array(), $values = array()) {
+ return compact('model', 'fields', 'values');
+ }
+
+ function read($model, $queryData = array()) {
+ return compact('model', 'queryData');
+ }
+
+ function update($model, $fields = array(), $values = array()) {
+ return compact('model', 'fields', 'values');
+ }
+
+ function delete($model, $id) {
+ return compact('model', 'id');
+ }
+
+}
+?>

0 comments on commit 0c0e5d1

Please sign in to comment.