Thanks to visit codestin.com
Credit goes to github.com

Skip to content

FrameworkBundle translator tests are failing for deps=high #15935

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
stof opened this issue Sep 26, 2015 · 7 comments
Closed

FrameworkBundle translator tests are failing for deps=high #15935

stof opened this issue Sep 26, 2015 · 7 comments
Labels

Comments

@stof
Copy link
Member

stof commented Sep 26, 2015

See https://travis-ci.org/symfony/symfony/jobs/82334660#L2124

this should be considered a critical issue. We need to bring our testsuite back to green to be meaningful (2.7.5 and 2.3.3 were released with red builds btw)

/cc @aitboudad

@stof stof added the Critical label Sep 26, 2015
@aitboudad
Copy link
Contributor

This due to #15738 /cc @mpdude

@mpdude
Copy link
Contributor

mpdude commented Sep 27, 2015

The entire test in question has been removed in 2.8. Honestly, I did not see what it was trying to test for (that has not been covered elsewhere).

If you want to keep it, the problem is that at the end of the test,

    // refresh cache when resources is changed in debug mode.
        $translator = $this->getTranslator($loader, array('cache_dir' => $this->tmpDir, 'debug' => true), 'yml');
        $translator->setLocale('fr');

After the cache has been warmed (in the same test, above), this now switches debug from false to true and expects the cache to become stale. Somehow that might have worked in the past, but in fact, the resource used (a YAML translation fixture) has not changed and so the cache is still considered fresh.

@mpdude
Copy link
Contributor

mpdude commented Sep 27, 2015

PR to remove the test is in #15943 /cc @stof

@aitboudad
Copy link
Contributor

@mpdude I think it shouldn't considered fresh because the resource used has been removed in the end of the test

@mpdude
Copy link
Contributor

mpdude commented Sep 27, 2015

You mean the 'resource_files' => $resourceFiles part is missing?

Then, you're loading a different set of resources so you need to use a different cache file. But that would also be pointless, because you'd warm the cache for a cache location A, assert that it works and then create a Translator with a different cache location B and make sure that there is no cached data there. IMO that does not add value.

@aitboudad
Copy link
Contributor

@mpdude I'm not talking about the test itself if it's useless or not, but only we should be sure that #15738 doesn't break something

@mpdude
Copy link
Contributor

mpdude commented Sep 27, 2015

The test in question was removed on 2.8 along with the changes from #15738.

On 2.7, the test is still there but fails due to symfony/config being installed as 2.8 (deps=high). So, let's remove the test on 2.7 as well (#15943).

fabpot added a commit that referenced this issue Sep 28, 2015
This PR was merged into the 2.7 branch.

Discussion
----------

Remove failing test to fix #15935

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #15935
| License       | MIT
| Doc PR        |

Test has been removed on 2.8 already in https://github.com/symfony/symfony/pull/15738/files#diff-990df0e8238847f8ae54e8227f295c22L107

Commits
-------

5392a0c Remove failing test
@fabpot fabpot closed this as completed Sep 28, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants