Florian Bruhin
19f7b92abb
Fix test_configinit.py
2018-02-19 22:09:43 +01:00
Florian Bruhin
c89e804653
Fix handling of invalid types in YamlConfig
2018-02-19 22:08:42 +01:00
Florian Bruhin
87e329aee3
Fix config.dump_userconfig() with defaults
2018-02-19 22:08:42 +01:00
Florian Bruhin
5eeb223338
Use a different directory for file prompt tests
...
This way they aren't influenced by the config_tmpdir fixture.
2018-02-19 22:08:42 +01:00
Florian Bruhin
f43c7fa360
Fix changing values in configutils.Values
2018-02-19 22:08:42 +01:00
Florian Bruhin
d3e8d46593
Use a real YamlConfig for tests
2018-02-19 22:08:42 +01:00
Florian Bruhin
cb631d532a
Fix getting global value from configutils.Values
2018-02-19 22:08:42 +01:00
Florian Bruhin
8b666d2d2e
Try to update settings in acceptNavigationRequest
...
This still doesn't seem to update them early enough?
2018-02-19 22:08:42 +01:00
Florian Bruhin
bd6e99158e
Get rid of the second deepcopy for config values
...
There were two reasons why we deepcopy mutable objects in the config:
1) So mutations don't mess with our internal/default values.
2) So we can detect mutations and update the config.
If we're going to copy the value for 1) in maybe_copy(), we know the original
value is not going to be mutated, so we can use that directly for self._mutables
instead of making another copy.
2018-02-19 22:07:53 +01:00
Florian Bruhin
93972ff3f1
Copy value before watching it for mutations in config
...
If we copy it afterwards, we are going to mutate the copied object.
2018-02-19 22:07:53 +01:00
Florian Bruhin
ddb914dc65
Refactor YAML init
2018-02-19 22:07:53 +01:00
Florian Bruhin
8504ad6ff3
Change how iterating over Config/YamlConfig works
2018-02-19 22:07:53 +01:00
Florian Bruhin
6abb42a066
Make saving in autoconfig.yml work
2018-02-19 22:07:53 +01:00
Florian Bruhin
4691753965
Avoid running change handlers on config.clear
2018-02-19 22:07:53 +01:00
Florian Bruhin
9c670e13ce
Make clearing config work
2018-02-19 22:07:53 +01:00
Florian Bruhin
a6b979539d
Add missing configutils.py
2018-02-19 22:07:53 +01:00
Florian Bruhin
14a69d9047
Fix lint
2018-02-19 22:07:53 +01:00
Florian Bruhin
7c1fb1d215
Refactor acceptNavigationRequest handling to use signals
2018-02-19 22:07:53 +01:00
Florian Bruhin
2a7998847f
Unset values properly
2018-02-19 22:07:53 +01:00
Florian Bruhin
74a7676111
Fix issues with per-domain proof-of-concept
2018-02-19 22:07:53 +01:00
Florian Bruhin
d09afdf0ee
Refactor handling of mutables with url/pattern in Config
...
This also should not copy stuff coming from the config if it's not needed.
2018-02-19 22:07:53 +01:00
Florian Bruhin
8551288efb
Start working on different per-URL storage
2018-02-19 22:07:53 +01:00
Florian Bruhin
5e50824042
Broken per-URL proof-of-concept
2018-02-19 22:07:53 +01:00
Florian Bruhin
4ed07d6062
Initial implementation of per-URL setting storage
2018-02-19 22:07:53 +01:00
Florian Bruhin
894da598d6
urlmatch: Remove dead code
2018-02-19 22:07:53 +01:00
Florian Bruhin
7033af816a
urlmatch: Add equality testcases
2018-02-19 22:07:53 +01:00
Florian Bruhin
eda15c53ad
urlmatch: Improve port error output
2018-02-19 22:07:53 +01:00
Florian Bruhin
d6ea9b1e47
urlmatch: Add test for invalid IPv6 URL
2018-02-19 22:07:53 +01:00
Florian Bruhin
174dd5dd9e
urlmatch: Remove performance FIXME
2018-02-15 18:47:07 +01:00
Florian Bruhin
5f6c8435a4
urlmatch: Add initial benchmark/hypothesis test
2018-02-15 18:47:07 +01:00
Florian Bruhin
41b7ac27d7
urlmatch: Postpone checking scheme
2018-02-15 18:47:07 +01:00
Florian Bruhin
5627a63265
urlmatch: Fix lint
2018-02-15 18:47:07 +01:00
Florian Bruhin
e161458f91
urlmatch: Add test cases for oddballs
2018-02-15 18:47:07 +01:00
Florian Bruhin
33b7c4bdd0
urlmatch: Fix and test port handling
2018-02-15 18:47:07 +01:00
Florian Bruhin
45cc1aaeb0
urlmatch: Add tests for file://
2018-02-15 18:47:07 +01:00
Florian Bruhin
a2836ba945
urlmatch: Make sure URLs are valid
2018-02-15 18:47:07 +01:00
Florian Bruhin
0a10a4f751
urlmatch: Add more tests for special schemes
2018-02-15 18:47:07 +01:00
Florian Bruhin
084d3de65b
urlmatch: Add support for data: and javascript:
2018-02-15 18:47:07 +01:00
Florian Bruhin
dae164abee
urlmatch: Get rid of scheme whitelist
...
There are more schemes like data: or javascript:, and we don't want to restrict
schemes anyways.
2018-02-15 18:47:03 +01:00
Florian Bruhin
28aadc4f96
urlmatch: Add tests for <all_urls>
2018-02-15 18:47:03 +01:00
Florian Bruhin
867f2a8e2b
urlmatch: Use None for match-all path
2018-02-15 18:47:03 +01:00
Florian Bruhin
8fd0690959
urlmatch: Fix handling of *:// as scheme
2018-02-15 18:47:03 +01:00
Florian Bruhin
a8a9cdd81e
urlmatch: Add more tests from Chromium
2018-02-15 18:47:03 +01:00
Florian Bruhin
978b90b5b1
urlmatch: Implement correct IP matching
2018-02-15 18:47:03 +01:00
Florian Bruhin
2d43a1d2e7
urlmatch: Use None as default for host
2018-02-15 18:47:03 +01:00
Florian Bruhin
5419d1caa1
urlmatch: Add glob escaping tests
2018-02-15 18:47:03 +01:00
Florian Bruhin
9092c3a87f
urlmatch: Increase debuggability
2018-02-15 18:47:03 +01:00
Florian Bruhin
faeca30dfa
urlmatch: Add more tests
2018-02-15 18:47:03 +01:00
Florian Bruhin
b7c3c10b87
urlmatch: Use class in test
2018-02-15 18:47:03 +01:00
Florian Bruhin
a8a976b324
urlmatch: Simplify/fix matching by using None as sentinel
2018-02-15 18:47:03 +01:00