# |
Jun 14th 2018, 12:25 |
lorenzo |
is something else calling alias again? |
# |
Jun 14th 2018, 12:25 |
lorenzo |
do you have a test connection declared? |
# |
Jun 14th 2018, 12:24 |
spriz |
that’s where I ran out of ideas |
# |
Jun 14th 2018, 12:24 |
spriz |
yurp |
# |
Jun 14th 2018, 12:23 |
lorenzo |
is this line being executed? https://github.com/cakephp/cakephp/blob/master/src/TestSuite/Fixture/FixtureManager.php#L128 |
# |
Jun 14th 2018, 12:23 |
lorenzo |
heh |
# |
Jun 14th 2018, 12:23 |
spriz |
wow, I tried to copy just the “<listener” line - great job @spriz :,) |
# |
Jun 14th 2018, 12:22 |
spriz |
<listeners> <listener class=“\Cake\TestSuite\Fixture\FixtureInjector” file=“./vendor/cakephp/cakephp/src/TestSuite/Fixture/FixtureInjector.php”> <arguments> <object class=“\Cake\TestSuite\Fixture\FixtureManager”/> </arguments> </listener> </listeners> |
# |
Jun 14th 2018, 12:22 |
spriz |
seems ok @lorenzo ``` |
# |
Jun 14th 2018, 12:21 |
spriz |
It’s 3.5.x btw |
# |
Jun 14th 2018, 12:21 |
lorenzo |
faulty phpunit.xml that has no fixtures lisetner? |
# |
Jun 14th 2018, 12:20 |
spriz |
Anyone have suggestions on why a cake app “all of a sudden” is looking in the `default` datasource rather than the `test`? :thinking_face: |
# |
Jun 14th 2018, 11:45 |
josbeir |
that would indeed be less work for the end user |
# |
Jun 14th 2018, 11:45 |
lorenzo |
right @josbeir |
# |
Jun 14th 2018, 11:35 |
josbeir |
$query->func()->concat => \ORM\blabla\concat() or something :P |
# |
Jun 14th 2018, 11:34 |
josbeir |
probably more for the expression functions and stuff ? |
# |
Jun 14th 2018, 11:30 |
neon1024 |
Won’t they all need to take a query instance? |
# |
Jun 14th 2018, 11:29 |
josbeir |
i'm all for that |
# |
Jun 14th 2018, 11:28 |
lorenzo |
I’m actually planning to introduce a bunch of namespaces functions for the ORM, to make query building easier |
# |
Jun 14th 2018, 11:27 |
neon1024 |
@lorenzo I see, yeah, it’s an interesting idea |
# |
Jun 14th 2018, 11:27 |
josbeir |
its a subject that will probably give heated discussions if it was implemented in a framework like cake |
# |
Jun 14th 2018, 11:26 |
lorenzo |
Static is the same idea, but again placed into a class for no good reason other than grouping and auto loading |
# |
Jun 14th 2018, 11:26 |
lorenzo |
You can do that with composer, though |
# |
Jun 14th 2018, 11:26 |
lorenzo |
Only if you include the file @neon1024 |
# |
Jun 14th 2018, 11:25 |
neon1024 |
Are namespace functions always available? |
# |
Jun 14th 2018, 11:25 |
neon1024 |
How does this differ from static? |
# |
Jun 14th 2018, 11:24 |
lorenzo |
State would need to be passed as arguments, forcing you to basically come up naturally with the idea of dependency injection |
# |
Jun 14th 2018, 11:24 |
LubosR |
josbeir, ok :) thanks anyway |
# |
Jun 14th 2018, 11:24 |
josbeir |
yeah i just remembered @lorenzo but its pretty verbose, not sure if its a better way to handle the problem |
# |
Jun 14th 2018, 11:24 |
lorenzo |
Another example is middleware, actually. We wouldn’t have the serialization problem if middleware was only a function with no state |
# |
Jun 14th 2018, 11:23 |
josbeir |
@Lubors, yes i just saw that too in the code :slightly_smiling_face: |
# |
Jun 14th 2018, 11:23 |
neon1024 |
I see, sorry I didn’t know about the feature. http://php.net/manual/en/language.namespaces.faq.php#language.namespaces.faq.innamespace |
# |
Jun 14th 2018, 11:23 |
LubosR |
josbeir, neon1024: Thanks. Since 3.6 and splitted setters/ getters, should we have setConfigShallow and getConfigShallow? |
# |
Jun 14th 2018, 11:22 |
lorenzo |
Well, since 5.6 you can write functions una namespace. But there are really annoying limitations, like no auto loading |
# |
Jun 14th 2018, 11:22 |
josbeir |
agree with @lorenzo thats its just a dummy 'namespace' class but there's no 'clean' alternative imo |
# |
Jun 14th 2018, 11:21 |
josbeir |
not needed for validation (in the example above) |
# |
Jun 14th 2018, 11:21 |
neon1024 |
Wouldn’t that sacrifice the interface contract? |
# |
Jun 14th 2018, 11:21 |
lorenzo |
just have the functions in a namespace, and import them by namespace |
# |
Jun 14th 2018, 11:21 |
josbeir |
validator_comparison() ? |
# |
Jun 14th 2018, 11:21 |
josbeir |
in your validation example, what would be the 'clean' alternative in php? prefix your function names? |
# |
Jun 14th 2018, 11:20 |
lorenzo |
not necessarily, @josbeir. More about how we communicate APIs. Having classes opens up the possibility of having state, and state is quite often not needed at all. Like in the validation class |