# |
Jul 11th 2017, 18:46 |
manuweg |
I'm try to get mark story's asset compress plugin working |
# |
Jul 11th 2017, 18:46 |
manuweg |
Hi |
# |
Jul 11th 2017, 17:55 |
ericadeefox |
anyone else on here use akkaweb's Facebook plugin? |
# |
Jul 11th 2017, 17:51 |
graziel |
you probably forgot to `use FilesystemsTrait;` |
# |
Jul 11th 2017, 17:18 |
awi |
$this->filesystem is an unknown method... |
# |
Jul 11th 2017, 17:11 |
awi |
WyriHaxismus i am trying to set up FlyPie with Webdav adaptor. I tried calling it in a table beforeMarshal to fetch the file before saving it to the database... I get some weird results... |
# |
Jul 11th 2017, 16:32 |
ericadeefox |
how to set `$this->session()` but for ALL of the integration tests? |
# |
Jul 11th 2017, 16:15 |
rudy1976s |
thank you all |
# |
Jul 11th 2017, 16:15 |
rudy1976s |
it was clearly there :scream: |
# |
Jul 11th 2017, 16:15 |
rudy1976s |
as usual I spend few time reading the cookbook |
# |
Jul 11th 2017, 16:15 |
hmic |
you should have a look in the callable arguments to collection functions too, if you need more custom stuff next time, this is really a nice and very mighty feature... |
# |
Jul 11th 2017, 16:14 |
hmic |
congrats rudy1976s! |
# |
Jul 11th 2017, 16:12 |
ericadeefox |
ahh cool |
# |
Jul 11th 2017, 16:12 |
rudy1976s |
$data = $collection->extract(‘node.left_relations.{*}.node’); |
# |
Jul 11th 2017, 16:12 |
rudy1976s |
I solved my problem apparently using |
# |
Jul 11th 2017, 16:11 |
ericadeefox |
^^right, which I had been doing, but now that I have incorporated FB SDK, I'm getting thrown all kinds of errors about how there's no stored session. so I'm thinking, OK, I guess for every test that requires session data, now I've got to set `$this->session()` for FB as well. which I'm not sure how to do that yet cos this is the first time I've used FB SDK. x_x |
# |
Jul 11th 2017, 16:10 |
jeremyharris |
you can use $this->session() in your integration tests to set data that will be passed to the created session object though |
# |
Jul 11th 2017, 16:10 |
jeremyharris |
integration tests create a session object which is then used, it doesn’t actually read from the session itself |
# |
Jul 11th 2017, 16:09 |
ericadeefox |
it requires a stored session, which apparently the way I had been doing it w my integration testing wasn't sufficient. so I go, OK, let's `session_start()` at the top of my tests. nope, it starts the session but then completely ignores the session data I set, like admin stuff, rendering most of my tests useless anyway. RIP perfect tests |
# |
Jul 11th 2017, 16:07 |
jeremyharris |
not sure your use case though, I don’t know anything about the fb sdk or what it expects |
# |
Jul 11th 2017, 16:06 |
jeremyharris |
if it requires it now, I guess so :( I usually have a login() method for my tests that set session data, which would allow setting fb related session data in it as well |
# |
Jul 11th 2017, 16:04 |
ericadeefox |
FB SDK has ruined my integration testing, which has been perfect for past several weeks. erring there is no stored session, so do I need to store specific session data for FB for each test I have that requires session data? |
# |
Jul 11th 2017, 16:02 |
jeremyharris |
the best |
# |
Jul 11th 2017, 16:02 |
jeremyharris |
procrastination! |
# |
Jul 11th 2017, 16:02 |
ericadeefox |
nbd I'm fiercely trying to avoid confronting the 56 errors my tests are throwing me :,( |
# |
Jul 11th 2017, 16:01 |
jeremyharris |
oh man I’m looking at the wrong thing haha |
# |
Jul 11th 2017, 16:01 |
ericadeefox |
I was on here: https://api.cakephp.org/3.0/source-class-Cake.Network.Response.html#652-669 |
# |
Jul 11th 2017, 16:01 |
jeremyharris |
well… https://api.cakephp.org/3.4/source-class-Cake.Http.Client.Response.html#296-305 |
# |
Jul 11th 2017, 16:01 |
jeremyharris |
setter/getter |
# |
Jul 11th 2017, 16:00 |
jeremyharris |
ah |
# |
Jul 11th 2017, 16:00 |
ericadeefox |
it returns it if statusCode() is null, you can use it to set the status tho, I thought |
# |
Jul 11th 2017, 16:00 |
jeremyharris |
gotta use withX methods to create new responses to return |
# |
Jul 11th 2017, 15:59 |
jeremyharris |
withStatus :) I think statusCode returns the status code |
# |
Jul 11th 2017, 15:58 |
ericadeefox |
ahh it's `$this->response->statusCode(200)` it was a hybrid of both our answers :P |
# |
Jul 11th 2017, 15:58 |
jeremyharris |
I think by default the status code is 200, so you can probably just return $this->response |
# |
Jul 11th 2017, 15:57 |
awi |
Everything else I can do by Exceptions |
# |
Jul 11th 2017, 15:57 |
ericadeefox |
it's like `$this->statusCode(200)` |
# |
Jul 11th 2017, 15:57 |
jeremyharris |
I think return $this->response->withStatusCode(200) |
# |
Jul 11th 2017, 15:57 |
awi |
just a 200, no template whatsoever |
# |
Jul 11th 2017, 15:57 |
awi |
How do i return a 200 |
# |
Jul 11th 2017, 15:56 |
rudy1976s |
yes |