-
Notifications
You must be signed in to change notification settings - Fork 30
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
Fix acessibilidade rebase #373
Conversation
Alterado a viewlet de site actions para retirar o atributo title dos links para adequar as regras de acessibilidade. Alterado a viewlet de serviços para incluir a descrição do objeto no atributo title do link.
ajuste dos links vazios acontent, anavigation e afooter para atender os critérios de acessibilidade
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
@@ -6,9 +6,9 @@ | |||
title view/description"> | |||
<span id="portal-title-1" | |||
tal:content="view/title_1">Secretaria de</span> | |||
<h1 id="portal-title" | |||
<div id="portal-title" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
IMO, this change could cause problems on third-party themes.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Unfortunately, this has to be done or we will have accessibility errors in ACCESS tool. We'll add an entry to changelog.
@@ -0,0 +1,268 @@ | |||
# -*- coding: utf-8 -*- | |||
from brasil.gov.portal.browser.viewlets.servicos import ServicosViewlet | |||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
remove this empty line.
self.request = self.layer['request'] | ||
self.adapter = SiteControlPanelAdapter(self.portal) | ||
self.browser = Browser(self.layer['app']) | ||
transaction.begin() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this is not needed.
class PortalLogoTestCase(AccessibilityTestCase): | ||
|
||
def portal_logo_tema_test(self, cor): | ||
""" Testa se o portal logo está presente em todos os temas |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
one-liner docstring.
class AcessibilidadeViewletTestCase(AccessibilityTestCase): | ||
|
||
def test_viewlet_is_present(self): | ||
""" Testa se a viewlet foi registrada corretamente |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
one-liner docstring.
) | ||
api.content.create( | ||
type='Link', | ||
container=self.servicos, | ||
id='servico-1', | ||
title=u'Servico 1' | ||
title=u'Servico 1', | ||
remoteUrl=u'http://www.google.com' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you're missing a semicolon at the end.
) | ||
api.content.create( | ||
type='Link', | ||
container=self.servicos, | ||
id='servico-2', | ||
title=u'Servico 2' | ||
title=u'Servico 2', | ||
remoteUrl=u'http://www.plone.org' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you're missing a semicolon at the end.
Boas práticas para o PR: Checklist
Foi aberta uma issue relativa a esse PR;
Foram adicionados testes unitários;
Foram adicionados testes robots;
Foram adicionados upgradeSteps;
Foi adicionada a modificação no CHANGES.rst do pacote, sempre no topo do arquivo (ou seja, na primeira linha do release ainda não lançado), contendo o seu nome de usuário do github e a referência ao issue que você está tratando (não esqueça de colocar no fim do arquivo a url para a issue, use o padrão do próprio arquivo);
PR não contém assuntos diferentes. PR's devem ter um objetivo claro para facilitar o review. Ex: não junte, num mesmo PR, alterações de code-analysis e de implementação. Faça um PR de code-analysis e depois o da implementação em si;
Evite muitos commits pequenos de um mesmo assunto no PR, sempre que possível efetue rebase;
Com a aprovação de plonegovbr/brasil.gov.temas#140 e o lançamento de um release de brasil.gov.temas poderemos remover
@unittest.expectedFailure
num outro PR para lançar um release de brasil.gov.portal.