Skip to content

Commit 0cd4653

Browse files
authored
Merge pull request #1 from tacxticx88/feature/new-mongodb-driver
New version of MongoDB ODM Driver
2 parents 54a9583 + b0faeb8 commit 0cd4653

File tree

109 files changed

+11308
-0
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

109 files changed

+11308
-0
lines changed

.codecov.yml

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
codecov:
2+
notify:
3+
require_ci_to_pass: yes
4+
5+
coverage:
6+
precision: 2
7+
round: down
8+
range: "65...90"
9+
10+
status:
11+
project:
12+
default:
13+
# Allow the coverage to drop by threshold %, and posting a success status.
14+
threshold: 0.5
15+
patch:
16+
default:
17+
# trial operation
18+
target: 0%
19+
changes: no
20+
21+
comment:
22+
layout: "header, diff"
23+
behavior: default
24+
require_changes: no
25+
26+
ignore:
27+
- ".git"
28+
- "*.yml"
29+
- "*.json"
30+
- "*.md"
31+
- "*.dist"
32+
# ignore folders and all its contents
33+
- ".github/.*"
34+
- "ide/.*"
35+
- "tests/.*"
36+
- "vendor/.*"

.editorconfig

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
# EditorConfig is awesome: http://EditorConfig.org
2+
3+
# top-most EditorConfig file
4+
root = true
5+
6+
[*]
7+
end_of_line = lf
8+
insert_final_newline = true
9+
indent_style = space
10+
indent_size = 4
11+
charset = utf-8
12+
trim_trailing_whitespace = true
13+
14+
[Makefile]
15+
indent_style = tab
16+
tab_width = 4
17+
18+
[*.md]
19+
trim_trailing_whitespace = false

.gitignore

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
composer.phar
2+
/vendor/
3+
4+
# Commit your application's lock file https://getcomposer.org/doc/01-basic-usage.md#commit-your-composer-lock-file-to-version-control
5+
# You may choose to ignore a library lock file http://getcomposer.org/doc/02-libraries.md#lock-file
6+
# composer.lock

Dockerfile

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
FROM toroia/phalcon-cli
2+
3+
RUN apk update \
4+
&& apk add --no-cache \
5+
-X http://dl-cdn.alpinelinux.org/alpine/edge/testing \
6+
php7-pecl-mongodb

Makefile

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
build:
2+
docker build -t incubator-mongodb .
3+
4+
exec:
5+
docker run --rm -it \
6+
-v $(CURDIR):/app \
7+
--network dev \
8+
incubator-mongodb bash
9+
10+
db:
11+
docker run --rm -d \
12+
--network dev \
13+
--name mongodb \
14+
-p 27017:27017 \
15+
mongo
16+
17+
test:
18+
docker run --rm -it \
19+
-v $(CURDIR):/app \
20+
--network dev \
21+
incubator-mongodb php -d display_errors=On -d error_reporting=E_ALL vendor/bin/codecept run

codeception.yml

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
actor_suffix: Tester
2+
3+
paths:
4+
# where the modules stored
5+
tests: tests
6+
log: tests/_output
7+
# directory for fixture data
8+
data: tests/_data
9+
# directory for custom modules (helpers)
10+
support: tests/_support
11+
envs: tests/_envs
12+
13+
settings:
14+
colors: true
15+
# Tests (especially functional) can take a lot of memory
16+
# We set a high limit for them by default.
17+
memory_limit: 1024M
18+
lint: true
19+
20+
coverage:
21+
# Disable Code Coverage by default to speed up Travis tests
22+
enabled: false
23+
24+
extensions:
25+
enabled:
26+
- Codeception\Extension\RunFailed
27+
28+
bootstrap: _bootstrap.php
29+
30+
params:
31+
# get params from environment vars
32+
- env

composer.json

Lines changed: 75 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,75 @@
1+
{
2+
"name": "phalcon/incubator-mongodb",
3+
"description": "Phalcon Incubator MongoDB",
4+
"keywords": [
5+
"framework",
6+
"phalcon",
7+
"incubator",
8+
"mongodb"
9+
],
10+
"homepage": "https://phalcon.io",
11+
"license": "BSD-3-Clause",
12+
"authors": [
13+
{
14+
"name": "Phalcon Team",
15+
"email": "[email protected]",
16+
"homepage": "https://phalcon.io/en/team"
17+
},
18+
{
19+
"name": "Contributors",
20+
"homepage": "https://github.com/phalcon/incubator-mongodb/graphs/contributors"
21+
}
22+
],
23+
"support": {
24+
"issues": "https://github.com/phalcon/incubator/issues",
25+
"source": "https://github.com/phalcon/incubator-mongodb",
26+
"forum": "https://forum.phalcon.io"
27+
},
28+
"require": {
29+
"php": ">=7.2",
30+
"ext-phalcon": "^4.0",
31+
"ext-mongodb": "*",
32+
"ext-json": "*"
33+
},
34+
"require-dev": {
35+
"phalcon/ide-stubs": "^4.0",
36+
"vimeo/psalm": "3.6.2",
37+
"squizlabs/php_codesniffer": "3.5.1",
38+
"codeception/codeception": "^4.1",
39+
"codeception/module-asserts": "^1.0.0",
40+
"mongodb/mongodb": "^1.6",
41+
"phpstan/phpstan": "^0.12.18",
42+
"vlucas/phpdotenv": "^2.5"
43+
},
44+
"autoload": {
45+
"psr-4": {
46+
"Phalcon\\Incubator\\MongoDB\\": "src/"
47+
},
48+
"files": [
49+
"src/functions.php"
50+
]
51+
},
52+
"autoload-dev": {
53+
"psr-4": {
54+
"Phalcon\\Incubator\\MongoDB\\Mvc\\Test\\Integration\\": "tests/integration/",
55+
"Phalcon\\Incubator\\MongoDB\\Mvc\\Test\\Unit\\": "tests/unit/",
56+
"Phalcon\\Incubator\\MongoDB\\Test\\Fixtures\\": "tests/_data/fixtures/"
57+
}
58+
},
59+
"minimum-stability": "dev",
60+
"prefer-stable": true,
61+
"archive": {
62+
"exclude": [
63+
"/.github",
64+
"/tests",
65+
".codacy.yml",
66+
".codecov.yml",
67+
"CHANGELOG.md",
68+
"codeception.yml",
69+
"phpcs.xml.dist",
70+
"phpstan.neon.dist",
71+
"phpunit.xml.dist",
72+
"psalm.xml.dist"
73+
]
74+
}
75+
}

0 commit comments

Comments
 (0)