This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Doctrine Configuration | |
doctrine: | |
dbal: | |
driver: "%database_driver%" | |
host: "%database_host%" | |
port: "%database_port%" | |
dbname: "%database_name%" | |
user: "%database_user%" | |
password: "%database_password%" | |
charset: UTF8 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
mappings: | |
# An array of mappings, which may be a bundle name or something else | |
mapping_name: | |
mapping: true | |
type: ~ | |
dir: ~ | |
alias: ~ | |
prefix: ~ | |
is_bundle: ~ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defun tonini-load-cabbage-project-settings () | |
(let ((project-setting-file (concat (cabbage-project-root) ".cabbage"))) | |
(when (file-readable-p project-setting-file) | |
(load project-setting-file)))) | |
(add-hook 'cabbage-after-project-hook 'tonini-load-cabbage-project-settings) | |
;; Run hook | |
(defun cabbage-project-ido-find-project () |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defun cabbage--run-single-ruby-file () | |
(interactive) | |
(let* ((name (file-name-nondirectory (car (split-string (buffer-file-name))))) | |
(name-buffer (format "*%s*" name))) | |
(if (get-buffer name-buffer) | |
(kill-buffer name-buffer)) | |
(ruby-compilation-run (buffer-file-name)))) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Special Form: let (bindings...) forms... | |
This special form binds variables according to bindings and then evaluates all of the forms in textual order. The let-form returns the value of the last form in forms. | |
Each of the bindings is either (i) a symbol, in which case that symbol is bound to nil; or (ii) a list of the form (symbol value-form), in which case symbol is bound to the result of evaluating value-form. If value-form is omitted, nil is used. | |
All of the value-forms in bindings are evaluated in the order they appear and before any of the symbols are bound. Here is an example of this: Z is bound to the old value of Y, which is 2, not the new value, 1. | |
(setq Y 2) | |
=> 2 | |
(let ((Y 1) | |
(Z Y)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public function test_admin_login() | |
{ | |
$password = 'admin'; | |
$admin = AdminFactory::create(["password" => $password]); | |
$this->visit("/admin"); | |
$this->fillField("_username", $admin->getUsername()); | |
$this->fillField("_password", 'admin'); | |
$this->pressButton('Anmelden'); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public function assertPageNotContainsText($text) | |
{ | |
$this->assertTrueWithoutExcpetion(function() use ($text) { | |
$this->assertSession()->pageTextNotContains($text); | |
}); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defstruct person | |
name | |
age | |
sex) | |
; The assignments have to be in the same order as the slots in the defined struct | |
(setq sam (make-person :name "Samuel Tonini" :age 32 :sex 'male )) | |
(person-name sam) ; Samuel Tonini | |
(person-age sam) ; 32 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defmacro inc (var) | |
(list 'setq var (list '1+ var))) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defmacro inc (var) | |
(list 'setq var (list '1+ var))) |