Skip to content

Commit

Permalink
Initial commit.
Browse files Browse the repository at this point in the history
  • Loading branch information
evansims committed Mar 27, 2023
1 parent bf029e7 commit b65fe04
Show file tree
Hide file tree
Showing 9 changed files with 164 additions and 3 deletions.
18 changes: 18 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
root = true

[*]
charset = utf-8
end_of_line = lf
insert_final_newline = true
indent_style = space
indent_size = 4
trim_trailing_whitespace = true

[*.md]
trim_trailing_whitespace = false

[*.{yml,yaml}]
indent_size = 2

[docker-compose.yml]
indent_size = 4
5 changes: 5 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
docs/ export-ignore
.github/ export-ignore
.editorconfig export-ignore
.gitattributes export-ignore
.gitignore export-ignore
6 changes: 6 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
version: 2
updates:
- package-ecosystem: "composer"
directory: "/"
schedule:
interval: "weekly"
20 changes: 20 additions & 0 deletions .github/workflows/rep_readonly.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
name: "Repo is Read Only"

on:
issues:
types: opened
pull_request_target:
types: opened

permissions:
issues: write
pull-requests: write

jobs:
action:
runs-on: ubuntu-latest
steps:
- uses: dessant/repo-lockdown@v3
with:
pr-comment: >
Thanks for your contribution! This repository is a metapackage, and therefor does not accept pull requests. Please see [the README](https://github.com/psr-discovery/all#usage) for details on making contributions to this project!
8 changes: 8 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
vendor/
coverage/
composer.lock
.php-cs-fixer.cache
.phpunit.result.cache
.DS_Store
composer.local.json
NOTES.md
2 changes: 1 addition & 1 deletion LICENSE → LICENSE.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
MIT License

Copyright (c) 2023 psr-mock
Copyright (c) 2023 Evan Sims

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
41 changes: 39 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,2 +1,39 @@
# http
Collection of svelte implementation providers for PSR-18, PSR-17 and PSR-7.
**Lightweight mock implementations of a [PSR-18 HTTP Client](https://www.php-fig.org/psr/psr-18/), [PSR-17 HTTP Factories](https://www.php-fig.org/psr/psr-17/) and [PSR-7 Messages](https://www.php-fig.org/psr/psr-7/) tailored to simplify unit testing.**

This is a meta-package that includes all of the [PSR Mock](https://github.com/psr-mock) utility suite's HTTP packages.

This suite is largely intended for inclusion in libraries like SDKs that consume PSRs without requiring hard dependencies on specific libraries.

- [Requirements](#requirements)
- [Installation](#installation)
- [Usage](#usage)
- [Contributing](#contributing)

## Requirements

- PHP 8.0+
- Composer 2.0+

## Installation

```bash
composer require psr-mock/http
```

## Usage

Usage instructions for each discovery library can be found at the links below:

- [PSR-18 HTTP Client](https://github.com/psr-mock/http-client-implementation)
- [PSR-17 HTTP Factories](https://github.com/psr-mock/http-factory-implementation)
- [PSR-7 HTTP Messages](https://github.com/psr-mock/http-message-implementation)

## Contributing

Contributions are welcome! Please create issues and pull requests on the repository for the specific discovery library you're interested in.

As a meta-package, this repository is not intended to accept contributions.

---

This library is not produced or endorsed by, or otherwise affiliated with, the PHP-FIG.
67 changes: 67 additions & 0 deletions composer.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
{
"name": "psr-mock/http",
"description": "Lightweight mock implementations of PSR-18, PSR-17 and PSR-7 tailored to simplify unit testing.",
"license": "MIT",
"type": "metapackage",
"keywords": [
"psr",
"discovery",
"psr-7",
"psr-17",
"psr-18",
"http-client-implementation",
"http-factory-implementation",
"http-message-implementation"
],
"authors": [
{
"name": "Evan Sims",
"email": "[email protected]",
"homepage": "https://evansims.com/"
}
],
"homepage": "https://github.com/psr-mock",
"require": {
"php": "^8.0",
"psr-mock/http-client-implementation": "^1.0",
"psr-mock/http-factory-implementation": "^1.0",
"psr-mock/http-message-implementation": "^1.0"
},
"provide": {
"psr/http-client-implementation": "^1.0",
"psr/http-factory-implementation": "^1.0",
"psr/http-message-implementation": "^1.0"
},
"minimum-stability": "dev",
"prefer-stable": true,
"autoload": {
"psr-4": {
"PsrDiscovery\\": "src"
}
},
"autoload-dev": {
"psr-4": {
"PsrDiscovery\\Tests\\": "tests"
}
},
"config": {
"optimize-autoloader": true,
"preferred-install": "dist",
"process-timeout": 0,
"sort-packages": true
},
"extra": {
"merge-plugin": {
"ignore-duplicates": false,
"include": [
"composer.local.json"
],
"merge-dev": true,
"merge-extra": false,
"merge-extra-deep": false,
"merge-scripts": false,
"recurse": true,
"replace": true
}
}
}
Empty file added docs/.gitkeep
Empty file.

0 comments on commit b65fe04

Please sign in to comment.