Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
D
digit-joinup-reference
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Terraform modules
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Code review analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
ec-europa
digit-joinup-reference
Commits
944c1212
Commit
944c1212
authored
2 months ago
by
Zoltan Horvath
Committed by
Ilias Dimopoulos
1 month ago
Browse files
Options
Downloads
Patches
Plain Diff
ISAICP-9492: Test coverage
parent
ce827674
No related branches found
No related tags found
1 merge request
!210
Patch release 2.2.1
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
tests/features/joinup_core/css_js_assets.feature
+20
-0
20 additions, 0 deletions
tests/features/joinup_core/css_js_assets.feature
web/modules/custom/joinup_event/joinup_event.module
+3
-0
3 additions, 0 deletions
web/modules/custom/joinup_event/joinup_event.module
with
23 additions
and
0 deletions
tests/features/joinup_core/css_js_assets.feature
0 → 100644
+
20
−
0
View file @
944c1212
@api
@group-d
Feature
:
When script kiddies are fetching the path of some outdated CSS / JS library
group, our system returns empty file responses instead of throwing and logging
errors.
Scenario Outline
:
Given
there are no preexisting log records on the site
And
I go to
"/sites/default/files/<asset url>"
Then
the response status code should be 200
And
there should be 0 log records
Examples
:
# The value of the "include" query string is the gz-compressed, base64
# encoded list of the libraries which should be injected into the page.
|
asset
url
|
# CSS - library: system/base.
|
css/css_notahash.css?delta=50&language=en&theme=ventuno&include=eJwrriwuSc3VT0osTgUAG5MEcA
|
# JS - at delta=0, there is an external library.
|
js/js_notahahsh.js?delta=0&language=en&theme=ventuno&include=eJzLT40vT00qyc_PKdZPKSotSMzRg_F1i3MTi0py8hNTUosAOvcPwg&scope=header
|
This diff is collapsed.
Click to expand it.
web/modules/custom/joinup_event/joinup_event.module
+
3
−
0
View file @
944c1212
...
...
@@ -190,6 +190,9 @@ function joinup_event_library_info_alter(array &$libraries, string $extension):
// Temporary support for Internet Explorer.
// @see https://citnet.tech.ec.europa.eu/CITnet/jira/browse/ISAICP-5564
// @see https://github.com/openeuropa/oe_webtools/pull/104
// This override also used in the test css_js_asset.feature. Please add a
// replacement library with an external JS asset for the test HTML head when
// this alteration is removed.
if
(
$extension
===
'oe_webtools'
)
{
$libraries
[
'drupal.webtools-smartloader'
][
'header'
]
=
TRUE
;
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment