Ach, Du liebes Internet: Eine Beschimpfung – und ein Kommentar zur Upload-Filter-Debatte

heise online Newsticker - 6. Juli 2018 - 12:00
Die Beschlüsse im EU-Parlament zur EU-Copyright-Reform lösten einen Sturm der Entrüstung aus. Der Film-Komponist Matthias Hornschuh hat eine andere Sicht.

Merkel: Deutschland droht Rückfall bei neuen Technologien

heise online Newsticker - 6. Juli 2018 - 11:00
Deutschland droht in Rückstand zu geraten, was neue Technologien betrifft, sagt Bundeskanzlerin Angela Merkel und beschwört Deutschlands Stärke.

Continuous Lifecycle und ContainerConf: Das Programm ist jetzt online

heise online Newsticker - 6. Juli 2018 - 10:00
Bis zum 21. September ist das Kombiticket für die beiden Konferenzen zu einem vergünstigten Preis zu haben. Das Programm ist jetzt online.

Office 365: Undokumentierte Funktion ermöglicht Nutzer-Überwachung

heise online Newsticker - 6. Juli 2018 - 10:00
Microsofts Online-Office-Suite erlaubt es Admins, die Aktivitäten von Mail-Nutzern sekundengenau auszulesen. Diese Funktion wurde bis jetzt geheim gehalten.

Massive CCC-Kritik an Polizei: Hausdurchsuchung bei Datenschutz-Aktivisten

heise online Newsticker - 6. Juli 2018 - 9:30
Im Juni gab es Durchsuchungen bei Mitgliedern von Zwiebelfreunde. Im Fokus waren sie als Zeugen, nicht als Verdächtige. Die Hintergründe scheinen fragwürdig.

Neue Mac-Malware greift Benutzer von Kryptowährungen an

heise online Newsticker - 6. Juli 2018 - 9:00
Der Schädling namens OSX.Dummy kursiert in Slack- und Discord-Gruppen und installiert eine Hintertür.

Social Media als Fundbüroersatz: Fallstricke für den Finder

heise online Newsticker - 6. Juli 2018 - 9:00
Wem gehört diese Geldbörse? Wer allzu blauäugig den Besitzer einer Fundsache über soziale Netzwerke sucht, kann rechtliche Probleme bekommen.

Update für Thunderbird – Mozilla behebt kritische Schwachstellen

heise online Newsticker - 6. Juli 2018 - 8:00
Im Mail-Client Thunderbird konnten Angreifer Programmabstürze via Scripting als Einfallstore missbrauchen. Ein Update wirkt solchen Szenarien entgegen.

EU-Copyright-Reform: Auch beim Leistungsschutzrecht Vorwürfe gegen Kritiker

heise online Newsticker - 6. Juli 2018 - 8:00
Kritiker sehen das freie Internet bedroht, wenn Europa Upload-Filter und ein Leistungsschutzrecht für Verlage bekommt. Nun melden sich Verleger zu Wort.

Expertin: "Wir sind völlig nackt" – Digitale Ethik als Wertekompass

heise online Newsticker - 6. Juli 2018 - 8:00
Brauchen wir eine Digitale Ethik für einen besseren gemeinsamen Umgang im Web? Ja, sagt Petra Grimm, Leiterin des Stuttgarter Instítuts für Digitale Ethik.

Hinten am Lastenesel : Die EU, der Lkw-Verkehr und die Abschaffung des Diesels

heise online Newsticker - 6. Juli 2018 - 7:30
Diesel? Ganz schlimm! Wissen wir aus der Zeitung. In aller Abschaffstimmung vergessen wir aber gern die Lastwagen. Dort fährt jetzt der EU-Regelhammer hinein.

Mitgelesene E-Mails: Google reagiert auf Gmail-Kontroverse

heise online Newsticker - 6. Juli 2018 - 7:00
Dass Entwickler von Gmail-Apps auch Mails lesen können, sorgte für Aufregung. Nun will Google seine Kunden beruhigen: "Niemand bei Google liest Ihre Mails".

PreviousNext: Automate your Drupal accessibility testing with aXe and NightwatchJS

Planet Drupal - 6. Juli 2018 - 1:52

Automated accessibility tools are only one part of ensuring a website is accessible, but it is a very simple part that can catch a lot of really easy to fix issues. Issues that when found and corrected early in the development cycle, can go a long way to ensuring they don’t get compounded into much larger issues down the track.

by Rikki Bochow / 6 July 2018

I’m sure we all agree that the accessibility of ALL websites is important. Testing for accessibility (a11y) shouldn’t be limited to Government services. It shouldn’t be something we need to convince non-government clients to set aside extra budget for. It certainly shouldn’t be left as a pre-launch checklist item that only gets the proper attention if the allocated budget and timeframe hasn’t been swallowed up by some other feature.

Testing each new component or feature against an a11y checker, as it’s being developed, takes a small amount of time. Especially when compared to the budget required to check and correct an entire website before launch -- for the very first time. Remembering to run such tests after a components initial development is one thing. Remembering to re-check later down the line when a few changes and possible regressions have gone through is another. Our brains can only do so much, so why not let the nice, clever computer help out?


NightwatchJS is going to be included in Drupal 8.6.x, with some great Drupal specific commands to make functional javascript testing in Drupal super easy. It's early days so the documentation is still being formed.  But we don't have to wait for 8.6.x to start using Nightwatch, especially when we can test interactions against out living Styleguide rather than booting up Drupal.

So lets add it to our build tools;

$ npm install nightwatch

and create a basic nightwatch.json file;

{ "src_folders": [   "app/themes/my_theme/src/",   "app/modules/custom/"   ], "output_folder": "build/logs/nightwatch", "test_settings": { "default": { "filter": "**/tests/*.js", "launch_url": "", "selenium_host": "", "selenium_port": "4444", "screenshots": { "enabled": true, "on_failure": true, "on_error": true, "path": "build/logs/nightwatch" }, "desiredCapabilities": { "browserName": "chrome" } } } }

We're pointing to our theme and custom modules as the source of our JS tests as we like to keep the tests close to the original JS. Our test settings are largely based on the Docker setup described below, with the addition of the 'filter' setting which searches the source for .js files inside a tests directory.

A test could be as simple as checking for an attribute, like the following example;

/** * @file responsiveTableTest.js. */ module.exports = { 'Responsive tables setup': (browser) => { browser .url(`${browser.launch_url}/styleguide/item-6-10.html?hideAll`) .pause(1000); browser.expect.element('td').to.have.attribute('data-label'); browser.end(); }, };

Which launches the Styleguides table component, waits a beat for the JS to initiate then checks that our td elements have the data-label that our JS added. Or is could be much more complex.

aXe: the Accessibility engine

aXe is a really nice tool for doing basic accessibility checks, and the Nightwatch Accessibility node module integrates aXe with Nightwatch so we can include accessibility testing within our functional JS tests without needing to write out the rules ourself. Even if you don't write any component specific tests with your Nightwatch setup, including this one accessibility test will give you basic coverage.

$ npm install nightwatch-accessibility

Then we edit our nightwatch.json file to include the custom_commands_path and custom_assertions_path;

{ "src_folders": ["app/themes/previousnext_d8_theme/src/"], "output_folder": "build/logs/nightwatch", "custom_commands_path": ["./node_modules/nightwatch-accessibility/commands"], "custom_assertions_path": ["./node_modules/nightwatch-accessibility/assertions"], "test_settings": {   ...   } }

Then write a test to do the accessibility check;

/** * @file Run Axe accessibility tests with Nightwatch. */ const axeOptions = { timeout: 500, runOnly: { type: 'tag', values: ['wcag2a', 'wcag2aa'], }, reporter: 'v2', elementRef: true, }; module.exports = { 'Accessibility test': (browser) => { browser .url(`${browser.launch_url}/styleguide/section-6.html`) .pause(1000) .initAccessibility() .assert.accessibility('.kss-modifier__example', axeOptions) .end(); }, };

Here we're configuring aXe core to check for wcag2a and wcag2aa, for anything inside the .kss-modifier__example selector of our Styleguide. Running this will check all of our components and tell us if it's found any accessibility issues. It'll also fail a build, so when hooked up with something like CircleCI, we know our Pull Requests will fail.

If we want to exclude a selector, instead of the .kss-modifier__example selector, we pass an include/exclude object { include: ['.kss-modifier__example'], exclude: ['.hljs'] }.

If you only add one test add one like this. Hopefully once you get started writing Nightwatch tests you'll see how easy it is and eventually add more :)

You can include the accessibility test within another functional test too, for example a modal component. You'll want to test it opens and closes ok, but once it's open it might have some accessibility issues that the overall check couldn't test for. So we want to re-run the accessibility assertion once it's open;

/** * @file dialogTest.js */ const axeOptions = require('../../../axeOptions.js'); // axeOptions are now shareable. const example = '#kssref-6-18 .kss-modifier__example'; const trigger = '#example-dialog-toggle'; const dialog = '.js-dialog'; module.exports = { 'Dialog opens': (browser) => { browser .url(`${browser.launch_url}/styleguide/item-6-18.html?hideAll`) .pause(1000) .initAccessibility();; browser.expect.element(dialog); browser.assert.attributeEquals(dialog, 'aria-hidden', 'false'); browser.assert.accessibility(example, axeOptions); browser.end(); }, };Docker

As mentioned above this all needs a little docker & selenium setup too. Selenium has docs for adding an image to Docker, but the setup basically looks like this;

@file docker-compose.yml services:   app:   [general docker image stuff...] selenium: image: selenium/standalone-chrome network_mode: service:app volumes: - /dev/shm:/dev/shm

Then depending on what other CI tools you're using you may need some extra config. For instance, to get this running on CircleCI, we need to tell it about the Selenium image too;

@file .circleci/config.yml jobs:   test:    docker:   [other docker images...] - image: selenium/standalone-chrome

If you're not using docker or any CI tools and just want to test this stuff locally, there's a node module for adding the selenium-webdriver but I haven't tested it out with Nightwatch.

Don’t forget the manual checks!

There’s a lot more to accessibility testing than just these kinds of automated tests. A layer of manual testing will always be required to ensure a website is truly accessible. But automating the grunt work of running a checklist against a page is one very nice step towards an accessible internet.

Tagged accessibility, CI, nightwatchjs, Functional Testing, aXe

Hook 42: DrupalCamp Asheville

Planet Drupal - 5. Juli 2018 - 19:19


Drupal Camp Asheville is next weekend! Join members of the Drupal community of all different skill levels and career paths for 3 days of science, trainings, sessions, and sprints.

Hook 42’s own Adam Bergstein will be sharing some insights on everybody’s favorite online Drupal testing environment, He recently took over ownership of the service, and we are excited to hear about where it is going next!

Along with helping organize the camp, our newest team member, Jonathan Daggerhart, will be leading an all day training on Drupal 8 Essentials.

Ohne Gentechnik: Hartweizen für die Sonne Afrikas

heise online Newsticker - 5. Juli 2018 - 18:30
Eine neue Getreidesorte kann im Tal des Senegal-Flusses sogar während der Trockenzeit wachsen. Gezüchtet wurde sie ohne Gentechnik.

Indien: Lynchmorde nach viralen Gerüchten – WhatsApp verspricht Änderungen

heise online Newsticker - 5. Juli 2018 - 18:00
In Indien häufen sich Berichte über Gerüchte auf WhatsApp, die Gewalt und sogar Lynchmorde auslösen. Die Regierung verlangt technische Gegenmaßnahmen.

JavaScript: Ember 3.2 hat einen neuen Helper

heise online Newsticker - 5. Juli 2018 - 18:00
Das Web-Framework Ember verfügt in der neuen Version über einen Helper zum Erstellen von Bindings in Templates.

Node Security Platform schließt Ende September

heise online Newsticker - 5. Juli 2018 - 16:30
Rund drei Monate nach dem Kauf von ^Lift Security, der Firma hinter der Node Security Platform, kündigt npm die Schließung der Plattform an.

Greenpeace lässt Superman-Drohne in AKW-Gebäude crashen

heise online Newsticker - 5. Juli 2018 - 16:30
Atomkraftwerke sind verwundbar. Das wollten Greenpeace-Aktivisten zeigen und steuerten zwei Drohnen in ein AKW-Gebäude.

Amazee Labs: Zurich Drupal Meetup - July

Planet Drupal - 5. Juli 2018 - 15:12
Zurich Drupal Meetup - July

We will host the next Durpal Meetup at our Amazee Labs offices in Zurich on 11 July.

Anli de Jager Thu, 07/05/2018 - 15:12

We'll focus our discussions on progressive decoupling, GraphQL, and Drupal.

So, if these topics interest you make sure to join us for an evening of great talks and collaboration.

We hope to see you there!

Date: Wednesday, 11 July 2018

Time: 6:30 PM - 9:00 PM

Venue: Amazee Labs, Förrlibuckstrasse 30, Zürich