<feed xmlns='http://www.w3.org/2005/Atom'>
<title>Odoo/addons/survey/tests, branch 14.0</title>
<subtitle>The current checkout of upstream Odoo</subtitle>
<link rel='alternate' type='text/html' href='http://erp.ceuconsult.com:9000/Odoo/'/>
<entry>
<title>[FIX] *: rephrase, correct typos</title>
<updated>2020-11-16T14:35:42+00:00</updated>
<author>
<name>Martin Trigaux</name>
<email>mat@odoo.com</email>
</author>
<published>2020-11-16T13:25:50+00:00</published>
<link rel='alternate' type='text/html' href='http://erp.ceuconsult.com:9000/Odoo/commit/?id=f5d0f4a1ebf406583889e9e04912d40c0693343e'/>
<id>f5d0f4a1ebf406583889e9e04912d40c0693343e</id>
<content type='text'>
Courtesy of Transifex's translators for reporting bad/unclear sentences.

closes odoo/odoo#61785

Related: odoo/enterprise#14751
Signed-off-by: Martin Trigaux (mat) &lt;mat@odoo.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Courtesy of Transifex's translators for reporting bad/unclear sentences.

closes odoo/odoo#61785

Related: odoo/enterprise#14751
Signed-off-by: Martin Trigaux (mat) &lt;mat@odoo.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>[FIX] *: correct typos and bad English</title>
<updated>2020-10-29T18:07:49+00:00</updated>
<author>
<name>Martin Trigaux</name>
<email>mat@odoo.com</email>
</author>
<published>2020-10-29T15:51:43+00:00</published>
<link rel='alternate' type='text/html' href='http://erp.ceuconsult.com:9000/Odoo/commit/?id=62a18bdb372e234107fd2099a2df5f9e3a442c96'/>
<id>62a18bdb372e234107fd2099a2df5f9e3a442c96</id>
<content type='text'>
Courtesy of translators
Reexport .pot of modified modules

closes odoo/odoo#61002

Related: odoo/enterprise#14485
Signed-off-by: Martin Trigaux (mat) &lt;mat@odoo.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Courtesy of translators
Reexport .pot of modified modules

closes odoo/odoo#61002

Related: odoo/enterprise#14485
Signed-off-by: Martin Trigaux (mat) &lt;mat@odoo.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>[FIX] *: typos and english incoherences</title>
<updated>2020-09-07T15:10:11+00:00</updated>
<author>
<name>Victor Feyens</name>
<email>vfe@odoo.com</email>
</author>
<published>2020-09-07T13:50:37+00:00</published>
<link rel='alternate' type='text/html' href='http://erp.ceuconsult.com:9000/Odoo/commit/?id=4214f05d454bca2b60fda3a288d529c098e84f77'/>
<id>4214f05d454bca2b60fda3a288d529c098e84f77</id>
<content type='text'>
Mainly transifex issues but also some errors found through 'grep' checks.

Fix typos and obscure english strings in xml contents, fields strings/helps, some docstrings, ...
ensuring correct translations base (and fallback when translations isn't available).

closes odoo/odoo#57206

Related: odoo/enterprise#13032
Signed-off-by: Martin Trigaux (mat) &lt;mat@odoo.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Mainly transifex issues but also some errors found through 'grep' checks.

Fix typos and obscure english strings in xml contents, fields strings/helps, some docstrings, ...
ensuring correct translations base (and fallback when translations isn't available).

closes odoo/odoo#57206

Related: odoo/enterprise#13032
Signed-off-by: Martin Trigaux (mat) &lt;mat@odoo.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>[IMP] http: remove default CSRF tokens expiration</title>
<updated>2020-08-09T14:49:12+00:00</updated>
<author>
<name>Olivier Dony</name>
<email>odo@odoo.com</email>
</author>
<published>2020-05-18T23:14:20+00:00</published>
<link rel='alternate' type='text/html' href='http://erp.ceuconsult.com:9000/Odoo/commit/?id=1af543a399dccf837f7305df2b5e3e1eb0e90da9'/>
<id>1af543a399dccf837f7305df2b5e3e1eb0e90da9</id>
<content type='text'>
Our CSRF tokens are based on the current user session, and automatically
expire as soon as the session does.

However, they also come with a default 1h expiration delay. This  proves
to be a frequent annoyance for users who pause more than 1h on a form
before submitting it (e.g. user logs out and browser sits on login page
until the next day).
It can even lead to blocking bugs, e.g. when the 1h expiration occurs in the
middle of taking a survey exam, and the user is never able to post the
answers that are only present in the state of the form they need to
post.

More generally, users have a hard time understanding those CSRF expiration
errors, and don't know how to react.

Longer default expiration times have been considered (e.g. 1 day or
1 week) but those would not bring any identified benefit in terms of
security, while still giving a chance that some users would experience
the incomprehensible HTTP 400 errors).

Attacks that can typically compromise the CSRF token (XSS, RCE)
can achieve as much, or more, on the system or user account than what is
possible with the token. And nothing generally prevents the attacker
from using the token immediately after capturing it, during the initial
attack, making the expiration delay rather irrelevant.

Given there seems to be no significant benefit in expiring the tokens
before the session itself, let's just keep them valid as long as the
session.

Note: sessions are GC'd automatically after 7 days of inactivity,
which gives an effective 1 week expiry for abandoned web forms anyway,
as the token expires with the session.

Additionally, fix `survey` module tests, that were using an incorrect
regex for extracting CSRF tokens.

closes odoo/odoo#51499

Signed-off-by: Olivier Dony (odo) &lt;odo@openerp.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Our CSRF tokens are based on the current user session, and automatically
expire as soon as the session does.

However, they also come with a default 1h expiration delay. This  proves
to be a frequent annoyance for users who pause more than 1h on a form
before submitting it (e.g. user logs out and browser sits on login page
until the next day).
It can even lead to blocking bugs, e.g. when the 1h expiration occurs in the
middle of taking a survey exam, and the user is never able to post the
answers that are only present in the state of the form they need to
post.

More generally, users have a hard time understanding those CSRF expiration
errors, and don't know how to react.

Longer default expiration times have been considered (e.g. 1 day or
1 week) but those would not bring any identified benefit in terms of
security, while still giving a chance that some users would experience
the incomprehensible HTTP 400 errors).

Attacks that can typically compromise the CSRF token (XSS, RCE)
can achieve as much, or more, on the system or user account than what is
possible with the token. And nothing generally prevents the attacker
from using the token immediately after capturing it, during the initial
attack, making the expiration delay rather irrelevant.

Given there seems to be no significant benefit in expiring the tokens
before the session itself, let's just keep them valid as long as the
session.

Note: sessions are GC'd automatically after 7 days of inactivity,
which gives an effective 1 week expiry for abandoned web forms anyway,
as the token expires with the session.

Additionally, fix `survey` module tests, that were using an incorrect
regex for extracting CSRF tokens.

closes odoo/odoo#51499

Signed-off-by: Olivier Dony (odo) &lt;odo@openerp.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>[FIX] survey: fix email sent multiples time</title>
<updated>2020-05-13T10:47:13+00:00</updated>
<author>
<name>jvm-odoo</name>
<email>jvm@odoo.com</email>
</author>
<published>2020-05-11T10:51:29+00:00</published>
<link rel='alternate' type='text/html' href='http://erp.ceuconsult.com:9000/Odoo/commit/?id=fbfe9109e2e4a4b502ee83a7cdd0d0a0afbc9335'/>
<id>fbfe9109e2e4a4b502ee83a7cdd0d0a0afbc9335</id>
<content type='text'>
Issue

	- Install Survey &amp; Contacts
	- Have 2 contacts with the same email address
          (e.g. test@example.com)
	- Create a survey, send it only to that
          email address

	Email sent 2 times

Cause

	When looking for partners linked
	to that email address, we do not
	provide any limit so the system
	send the email to all partners
	found.

Solution

	If I set one email address,
	I expect one email to be sent.

	So, the solution would be to
	apply a limit of 1 when login
	is not required.

OPW-2247693

closes odoo/odoo#51155

X-original-commit: 55b1cc3108d6b672f10ece26db7e13a65ff655d3
Signed-off-by: Thibault Delavallee (tde) &lt;tde@openerp.com&gt;
Signed-off-by: Jason Van Malder (jvm) &lt;jvm@odoo.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Issue

	- Install Survey &amp; Contacts
	- Have 2 contacts with the same email address
          (e.g. test@example.com)
	- Create a survey, send it only to that
          email address

	Email sent 2 times

Cause

	When looking for partners linked
	to that email address, we do not
	provide any limit so the system
	send the email to all partners
	found.

Solution

	If I set one email address,
	I expect one email to be sent.

	So, the solution would be to
	apply a limit of 1 when login
	is not required.

OPW-2247693

closes odoo/odoo#51155

X-original-commit: 55b1cc3108d6b672f10ece26db7e13a65ff655d3
Signed-off-by: Thibault Delavallee (tde) &lt;tde@openerp.com&gt;
Signed-off-by: Jason Van Malder (jvm) &lt;jvm@odoo.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>[FIX] survey: fix quick access test</title>
<updated>2020-04-20T08:17:50+00:00</updated>
<author>
<name>Thibault Delavallée</name>
<email>tde@odoo.com</email>
</author>
<published>2020-04-14T08:11:09+00:00</published>
<link rel='alternate' type='text/html' href='http://erp.ceuconsult.com:9000/Odoo/commit/?id=fa55c0e96399667a954cb2addc7a585585ca9bd7'/>
<id>fa55c0e96399667a954cb2addc7a585585ca9bd7</id>
<content type='text'>
Purpose of this commit is to clean test that broke nightly recently.

Task ID

closes odoo/odoo#49759

X-original-commit: 61f9b05ccc61a7e00dc5cc43cb1f8196195bee60
Signed-off-by: Thibault Delavallee (tde) &lt;tde@openerp.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Purpose of this commit is to clean test that broke nightly recently.

Task ID

closes odoo/odoo#49759

X-original-commit: 61f9b05ccc61a7e00dc5cc43cb1f8196195bee60
Signed-off-by: Thibault Delavallee (tde) &lt;tde@openerp.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>[IMP] survey: cascade archive of a survey to its badge</title>
<updated>2020-04-03T12:59:29+00:00</updated>
<author>
<name>Thibault Delavallée</name>
<email>tde@odoo.com</email>
</author>
<published>2020-04-03T09:58:57+00:00</published>
<link rel='alternate' type='text/html' href='http://erp.ceuconsult.com:9000/Odoo/commit/?id=6cf824933f36cd8111ec61a2bb2da5bb99a2ec6a'/>
<id>6cf824933f36cd8111ec61a2bb2da5bb99a2ec6a</id>
<content type='text'>
Purpose of this commit is to synchronize active status of certifications to
their badges. When archiving or activating a certification, its badge is also
archived or activated.

Task ID 2170708
Community PR odoo/odoo#46563</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Purpose of this commit is to synchronize active status of certifications to
their badges. When archiving or activating a certification, its badge is also
archived or activated.

Task ID 2170708
Community PR odoo/odoo#46563</pre>
</div>
</content>
</entry>
<entry>
<title>[IMP] survey: add python tests/tours to test the survey sessions</title>
<updated>2020-03-31T15:16:02+00:00</updated>
<author>
<name>Aurélien Warnon</name>
<email>awa@odoo.com</email>
</author>
<published>2020-03-25T09:35:38+00:00</published>
<link rel='alternate' type='text/html' href='http://erp.ceuconsult.com:9000/Odoo/commit/?id=6405ffd483794db6cf576feb9ad77d0bc78e8f04'/>
<id>6405ffd483794db6cf576feb9ad77d0bc78e8f04</id>
<content type='text'>
PURPOSE

This commit adds a big flow test/tours to the survey sessions, for the host
point of view.
This will avoid breaking the feature with future changes, as it contains some
tricky and complex mechanics (especially the screens chaining).

SPECS

The tour tests the whole host point of view.

Break down of the testing/tour main points:
- Create the survey session
- Check our attendees are accounted for
- Open the 'session manager'
- Display the nickname question, and move to the next one (as answers are not
  displayed for nickname questions)
- Check answers are correctly displayed for the 3 'simple' question types
  (text, date, datetime)
- Move to the choice question and check that answers are displayed
- If everything is correctly displayed, move to the next question
- On the scored choice question, check that the screens are correctly chained:
  no results displayed -&gt; results displayed -&gt; correct/incorrect answers -&gt;
  leaderboard
- On the scored + timed multiple choice question, check the same than previous
  question, except that the results are supposed to be displayed automatically
  when the question timer runs out
- Test the 'back' behavior and check that screens are reversed correctly
- Check that our final leaderboard is correct based on attendees answers
- Close the survey session

LINKS

PR #46768
Task 2208574</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
PURPOSE

This commit adds a big flow test/tours to the survey sessions, for the host
point of view.
This will avoid breaking the feature with future changes, as it contains some
tricky and complex mechanics (especially the screens chaining).

SPECS

The tour tests the whole host point of view.

Break down of the testing/tour main points:
- Create the survey session
- Check our attendees are accounted for
- Open the 'session manager'
- Display the nickname question, and move to the next one (as answers are not
  displayed for nickname questions)
- Check answers are correctly displayed for the 3 'simple' question types
  (text, date, datetime)
- Move to the choice question and check that answers are displayed
- If everything is correctly displayed, move to the next question
- On the scored choice question, check that the screens are correctly chained:
  no results displayed -&gt; results displayed -&gt; correct/incorrect answers -&gt;
  leaderboard
- On the scored + timed multiple choice question, check the same than previous
  question, except that the results are supposed to be displayed automatically
  when the question timer runs out
- Test the 'back' behavior and check that screens are reversed correctly
- Check that our final leaderboard is correct based on attendees answers
- Close the survey session

LINKS

PR #46768
Task 2208574</pre>
</div>
</content>
</entry>
<entry>
<title>[IMP] survey: perform a quick linting in tests</title>
<updated>2020-03-31T07:33:50+00:00</updated>
<author>
<name>Thibault Delavallée</name>
<email>tde@odoo.com</email>
</author>
<published>2020-03-30T06:49:43+00:00</published>
<link rel='alternate' type='text/html' href='http://erp.ceuconsult.com:9000/Odoo/commit/?id=549968bdfe3ce0d31cc53c1ff6f1444bf45812a1'/>
<id>549968bdfe3ce0d31cc53c1ff6f1444bf45812a1</id>
<content type='text'>
Notably

  * have tools and helpers in a SurveyCase and let SurveyCommon bet the
    one with data;
  * remove unnecessary with_user, replaced by standard one;
  * move all tools in SurveyCase to help reusing them;</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Notably

  * have tools and helpers in a SurveyCase and let SurveyCommon bet the
    one with data;
  * remove unnecessary with_user, replaced by standard one;
  * move all tools in SurveyCase to help reusing them;</pre>
</div>
</content>
</entry>
<entry>
<title>[FIX] survey: ignore extra questions of random surveys</title>
<updated>2020-03-31T07:33:43+00:00</updated>
<author>
<name>Paul Morelle</name>
<email>pmo@odoo.com</email>
</author>
<published>2020-03-11T10:07:22+00:00</published>
<link rel='alternate' type='text/html' href='http://erp.ceuconsult.com:9000/Odoo/commit/?id=b105240252c8e7349c7d381b79571d2436f68c15'/>
<id>b105240252c8e7349c7d381b79571d2436f68c15</id>
<content type='text'>
When a random survey does not use all the questions available in a page
because of the random_questions_count field, _get_answers_correctness
was still including them in the skipped category.

This commit ensures that those questions are not included in the result,
and adds a test that checks it.

closes odoo/odoo#47362

Signed-off-by: Thibault Delavallee (tde) &lt;tde@openerp.com&gt;
X-original-commit: 4df43478979766112ae70624deae9c25f40a3349</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
When a random survey does not use all the questions available in a page
because of the random_questions_count field, _get_answers_correctness
was still including them in the skipped category.

This commit ensures that those questions are not included in the result,
and adds a test that checks it.

closes odoo/odoo#47362

Signed-off-by: Thibault Delavallee (tde) &lt;tde@openerp.com&gt;
X-original-commit: 4df43478979766112ae70624deae9c25f40a3349</pre>
</div>
</content>
</entry>
</feed>
