Search API for documents, data, research, people, etc. You can search by subject (keyword), person, location, or time period.
- Install PHP and Composer
- Install any project dependencies via composer:
composer install
composer create-project wp-coding-standards/wpcs:dev-master --no-dev -n standards/wpcs
./vendor/bin/phpcs -vvv -w --config-set installed_paths '../../../standards/gios/,../../../standards/wpcs/'
vendor/bin/phpunit
Make sure to add this line to your config.conf:
TestSolrApiUrl=http://jilliantessa.me:8983/solr/gios-dev/select
This will be the url to the Solr server the test will use.
vendor/bin/phpspec run -c .phpspec.yml
vendor/bin/phpcs --standard=GIOS src test
If you add a new class (or rename a class) file in the src folder you will need to run
composer dump-autoload
This will regenerate the class auto-loader which does dependency mapping and creates static load order in the vendor folder.
See config.conf.example for example configuration. The following are entries for your config.conf file, located in the project root, that you must fill out for Search API to work properly:
SolrApiUrl=http://127.0.0.1:8983/solr/gios/selectspecifies the SOLR endpoint URL.TestSolrApiUrl=http://jilliantessa.me:8983/solr/gios-dev/selectspecifies the SOLR endpoint URL used in tests.StanfordNerPath=lib/stanford-ner-2015-04-20/specifies target path for Stanford's NER library.
The Stanford NER library is required for for the Search API to function. This is available here. Unpack it anywhere you choose, but be sure to include the root path of the Stanford NER library in your configuration file.