Skip to content

Commit e3594ac

Browse files
135 support dbtable (#178)
* ci: added drop-all to the test setup * chore: added missing methods to the docblock for better autocompletion * fix: fixed confusing functionality for getTables & getAllTables * fix: Renamed getAllViews to getViews for better Laravel naming compatibility * fix: Renamed getAllAnalyzers to getAnalyzers for better Laravel naming compatibility * fix: Renamed getAllGraphs to getGraphs for better Laravel naming compatibility * docs: streamlined styling and added functions * test fixed schema method calls * chore cleared unused function * test fixed default endpoint * feat Extended db:show with arangodb functionality * ci: ensure migrations are converted
1 parent 381d12a commit e3594ac

20 files changed

+518
-53
lines changed

bin/qa.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,6 @@ echo "Run PHPStan"
1010

1111
echo "Test package from within phpunit"
1212
./vendor/bin/testbench convert:migrations
13-
./vendor/bin/testbench migrate:fresh --path=TestSetup/Database/Migrations --path=vendor/orchestra/testbench-core/laravel/migrations/ --realpath --seed
13+
./vendor/bin/testbench migrate:fresh --drop-all --path=TestSetup/Database/Migrations --path=vendor/orchestra/testbench-core/laravel/migrations/ --realpath --seed
1414
./vendor/bin/testbench package:test --coverage --min=80 tests
1515

bin/test.sh

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
#!/usr/bin/env bash
22
printf "\nRun tests\n"
3-
./vendor/bin/testbench migrate:fresh --path=TestSetup/Database/Migrations --path=vendor/orchestra/testbench-core/laravel/migrations/ --realpath --seed
3+
./vendor/bin/testbench convert:migrations
4+
./vendor/bin/testbench migrate:fresh --drop-all --path=TestSetup/Database/Migrations --path=vendor/orchestra/testbench-core/laravel/migrations/ --realpath --seed
45
./vendor/bin/testbench package:test --coverage --min=80 tests

docs/console-commands.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,15 @@ In addition, you have the option to clear the following in ArangoDB:
99
* --drop-graphs: drop all named graphs
1010
* --drop-all: drop all of the above: tables, analyzers, views and graphs
1111

12+
## db:show
13+
db:show gives you an overview of the current database and its tables.
14+
In addition to the default Laravel options, you have the following:
15+
16+
* --analyzers: show a list of available analyzers
17+
* --views: show a list of available views
18+
* --graphs: show a list of available named graphs
19+
* --system: include system tables in the table list
20+
1221
## Migrations
1322
_**Migrations for ArangoDB use a different Schema blueprint. Therefore, you either need to run the convert:migrations
1423
command first, or convert them manually**_

docs/migrations.md

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -88,21 +88,26 @@ Schema::dropView($viewName);
8888
## Analyzers (ArangoSearch)
8989
You can create, edit or delete an ArangoDB Analyzer.
9090

91-
### New Analyzer
91+
### New analyzer
9292
```php
9393
Schema::createAnalyzer($name, $type, $properties, $features);
9494
```
9595

96-
### Replace Analyzer
96+
### Replace analyzer
9797
```php
9898
Schema::replaceAnalyzer($name, $type, $properties, $features);
9999
```
100100

101-
### Delete Analyzer
101+
### Delete analyzer
102102
```php
103103
Schema::dropAnalyzer($name);
104104
```
105105

106+
### Delete all analyzers
107+
```php
108+
Schema::dropAnalyzers($name);
109+
```
110+
106111
## Named Graphs
107112
Named graphs are predefined managed graphs which feature integrity checks
108113
compared to anonymous graphs.
@@ -126,7 +131,7 @@ Schema::getGraph($name);
126131

127132
### Get all graphs
128133
```php
129-
Schema::getAllGraphs();
134+
Schema::getGraphs();
130135
```
131136

132137
### Delete a graph
@@ -141,5 +146,5 @@ Schema::dropGraphIfExists($name);
141146

142147
### Delete all graphs
143148
```php
144-
Schema::dropAllGraphs();
149+
Schema::dropGraphs();
145150
```

phpunit.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@
3030
<php>
3131
<env name="APP_KEY" value="AckfSECXIvnK5r28GVIWUAxmbBSjTsmF"/>
3232
<env name="ARANGODB_VERSION" value="3.12"/>
33-
<env name="DB_ENDPOINT" value="https://localhost:8529"/>
33+
<env name="DB_ENDPOINT" value="http://localhost:8529"/>
3434
<env name="LARAVEL_VERSION" value="11"/>
3535
<env name="RAY_ENABLED" value="(true)"/>
3636
<env name="SEND_CACHE_TO_RAY" value="(false)"/>

0 commit comments

Comments
 (0)