* Make sure data directory is directory, not a file
* Add a test for zip archive import
Also tests the saving of the archive file name and source filename
* Add TODOs - no functional changes
* Cosmetic cleanups
* Revert importer API changes for archive file name parameter
Fixes#2963
- restore binary compatibility to the API
- hoist the handling of both fileSource and archiveFileName from
TabularImportingParserBase and TreeImportingParserBase to
ImportingParserBase so that there's only one copy. These 3 classes are
all part of the internal implementation, so there should be no
compatibility issue.
* Revert weird flow of control for import options metadata
This reverts the very convoluted control flow that was introduced
when adding the input options to the project metadata. Instead
the metadata is all handled in the importer framework rather than
having to change APIs are have individual importers worry about
it.
The feature never had test coverage, so that is still to be added.
* Add test for import options in project metadata & fix bug
Fixes bug where same options object was being reused and overwritten,
so all copies in the list ended up the same.
Implemented Citation needed Cconstraint as part of #2354
Test class added with appropriate testc cases
Updated severity level to critical as well as the messages
merged unsourced and citation-needed scrutinizer
updated severity levels and warning messages
* Add One-of qualifier value property constraint
Implemented one-of qualifier value property constraint as part of #2354
* Test class added
* Test cases updated and working fine
* resolved merge conflicts
* Move findValues method to EditScrtuinzer
As findValues method is not concerned with fetching, therefore moving it to EditScrtuinizer
* updated test classes accordingly
* updated test classes accordingly
* test files updated after shifting the findValues method
* Revert "Revert "Reused Constraint IDs and Parameter PIDs (#2893)""
This reverts commit 4c739be843.
* Reuse Constraint IDs and Parameter PIDs
After the cleanup of MockConstraintFetcher, using constraint IDs and property IDs defined in the corresponding scrtinizer for the test files.
After adding the code for fetching parameters for different scrutinizers in their corresponding classes, we should remove the redundant code from the ConstraintFetcher
* Add ItemRequires Constraint
Implemented Item requires constraint as part of #2354
* done with implementation of ItemRequiresScrutinizer Class
* Test class added with suitable test cases
* Implemented RestrictedPosition Scrutinizer tests using mocks
Added RestrictedPositionConstraint class and updated test cases using mocks
* Tests updated & working fine
* Implemented DistinctValueScrutinizer tests using mcokito
Added inner class to the scrutinizer and updated the tests using mocks.
* Tests updated-testNoIssue added
* all tests updated & working fine
* Implemented SingleValue Scrutinizer tests using mocks
Updated test class & added inner class to the scrutinizer
* tests updated
* Updated SingleValueConstraint class
updated test class by creating mocks for ConstraintFetcher
Implemented tests for conflicts-with scrutinizer using mocks
Added testcase for no statementList & multiple constraint.
Implemented tests using mock for conflicts-with scrutinizer
Implemented tests using mock for conflicts-with scrutinizer
Added test case for multiple constraints
Added test case for multiple constraints
Closes#1612
Merges @afkbrb work to finish @wetneb protype, including:
* adding support for OAuth in addition to basic auth
* supporting registration of single user Wikidata OAuth consumers.
* adding extensive tests
* cleaning up the login dialog
This depends on the next release of the Wikidata Toolkit, but we're currently publishing our own snapshot that includes the necessary changes (thanks @wetneb!)
Co-authored-by: Antonin Delpeuch <antonin@delpeuch.eu>
Updates Wikidata-Toolkit to 0.11.0
This enables the following improvements:
- https://github.com/Wikidata/Wikidata-Toolkit/issues/431
- https://github.com/Wikidata/Wikidata-Toolkit/issues/456
This closes#2196 although the feature will not be enabled until 3.4 for technical reasons
(the openrefine-3.3 tag on Wikidata can only be applied by an AbuseFilter, not manually through
the API).
* Update WDTK and add timeouts to Wikidata editing, closes#2211.
* Explicitly add wdtk-util as a dependency
* Catch MediaWikiApiError following change of interface