Skip to content

Enable autoFields in order to resolve lazy loading translated entities.#13411

Merged
markstory merged 4 commits into
cakephp:masterfrom
robertpustulka:fix-13181
Jul 13, 2019
Merged

Enable autoFields in order to resolve lazy loading translated entities.#13411
markstory merged 4 commits into
cakephp:masterfrom
robertpustulka:fix-13181

Conversation

@robertpustulka

Copy link
Copy Markdown
Member

This resolves #13181, the fix also resolves a failing test case #13182

@codecov

codecov Bot commented Jul 12, 2019

Copy link
Copy Markdown

Codecov Report

Merging #13411 into master will increase coverage by <.01%.
The diff coverage is 100%.

Impacted file tree graph

@@             Coverage Diff              @@
##             master   #13411      +/-   ##
============================================
+ Coverage     90.94%   90.94%   +<.01%     
  Complexity    13997    13997              
============================================
  Files           523      523              
  Lines         36318    36319       +1     
============================================
+ Hits          33029    33030       +1     
  Misses         3289     3289
Impacted Files Coverage Δ Complexity Δ
src/ORM/LazyEagerLoader.php 95% <100%> (+0.08%) 21 <0> (ø) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 1c122d6...06b44f6. Read the comment docs.

1 similar comment
@codecov

codecov Bot commented Jul 12, 2019

Copy link
Copy Markdown

Codecov Report

Merging #13411 into master will increase coverage by <.01%.
The diff coverage is 100%.

Impacted file tree graph

@@             Coverage Diff              @@
##             master   #13411      +/-   ##
============================================
+ Coverage     90.94%   90.94%   +<.01%     
  Complexity    13997    13997              
============================================
  Files           523      523              
  Lines         36318    36319       +1     
============================================
+ Hits          33029    33030       +1     
  Misses         3289     3289
Impacted Files Coverage Δ Complexity Δ
src/ORM/LazyEagerLoader.php 95% <100%> (+0.08%) 21 <0> (ø) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 1c122d6...06b44f6. Read the comment docs.


$entity = $table->get(1);
$result = $table->loadInto($entity, ['Authors']);
$this->assertSame($entity, $result);

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should there be assertions that the Authors + translation were loaded?

@markstory markstory merged commit 36b139a into cakephp:master Jul 13, 2019
markstory added a commit that referenced this pull request Jul 13, 2019
@robertpustulka robertpustulka deleted the fix-13181 branch July 19, 2019 12:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Translate behavior breaks loadInto for belongsTo associations

5 participants