You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@allura.apache.org by br...@apache.org on 2015/04/15 16:55:02 UTC

[3/8] allura git commit: Consolidate test config

Consolidate test config


Project: http://git-wip-us.apache.org/repos/asf/allura/repo
Commit: http://git-wip-us.apache.org/repos/asf/allura/commit/97eb3ac0
Tree: http://git-wip-us.apache.org/repos/asf/allura/tree/97eb3ac0
Diff: http://git-wip-us.apache.org/repos/asf/allura/diff/97eb3ac0

Branch: refs/heads/db/7870
Commit: 97eb3ac0d891d81629083ec0865594baf890c3f9
Parents: a6a3b49
Author: Dave Brondsema <da...@brondsema.net>
Authored: Thu Apr 9 18:34:47 2015 -0400
Committer: Dave Brondsema <da...@brondsema.net>
Committed: Tue Apr 14 17:38:03 2015 -0400

----------------------------------------------------------------------
 Allura/allura/websetup/bootstrap.py |  1 -
 Allura/development.ini              | 43 ++++++-----------------------
 Allura/test.ini                     | 47 ++++----------------------------
 3 files changed, 13 insertions(+), 78 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/allura/blob/97eb3ac0/Allura/allura/websetup/bootstrap.py
----------------------------------------------------------------------
diff --git a/Allura/allura/websetup/bootstrap.py b/Allura/allura/websetup/bootstrap.py
index bb89995..ed76c15 100644
--- a/Allura/allura/websetup/bootstrap.py
+++ b/Allura/allura/websetup/bootstrap.py
@@ -90,7 +90,6 @@ def bootstrap(command, conf, vars):
     # Clean up all old stuff
     ThreadLocalORMSession.close_all()
     c.user = c.project = c.app = None
-    database = conf.get('db_prefix', '') + 'project:test'
     wipe_database()
     try:
         g.solr.delete(q='*:*')

http://git-wip-us.apache.org/repos/asf/allura/blob/97eb3ac0/Allura/development.ini
----------------------------------------------------------------------
diff --git a/Allura/development.ini b/Allura/development.ini
index 4a4f18c..68f2136 100644
--- a/Allura/development.ini
+++ b/Allura/development.ini
@@ -30,15 +30,15 @@
 ; You may copy this file to make a new configuration file (e.g. production.ini)
 ; Just use the new file name instead of development.ini for any paster commands you run.
 
-
-; TODO:
-; remove test config
-; clarify debug settings
-
 [DEFAULT]
+; WARNING: *THE LINE BELOW MUST BE CHANGED ON A PRODUCTION ENVIRONMENT*
+; Debug mode will enable the interactive debugging tool, allowing ANYONE to
+; execute malicious code after an exception is raised.
 debug = true
-; Uncomment and replace with the address which should receive any error reports
+
+; If you want to receive an email for every unhandled HTTP 500 error, set your email address here:
 ;email_to = you@yourdomain.com
+error_email_from = paste@localhost
 
 ; SMTP settings for outgoing mail
 smtp_tls = false
@@ -51,7 +51,6 @@ smtp_port = 8826
 ; Reply-To and From address often used in email notifications:
 forgemail.return_path = noreply@sf.net
 
-error_email_from = paste@localhost
 ; Used to uniquify references to static resources, can be a timestamp or any unique value
 ; This should be updated each time you deploy (or make significant changes, like new tools, new css)
 build_key=1276635823
@@ -61,6 +60,7 @@ use = egg:Paste#http
 host = 0.0.0.0
 port = 8080
 
+; for profiling with https://pypi.python.org/pypi/keas.profile
 [filter-app:profile]
 use=egg:keas.profile#profiler
 next=main
@@ -75,6 +75,7 @@ site_name = Allura
 domain = localhost
 base_url = http://localhost:8080
 
+; Used by Turbogears / Pylons in some cases.  Not particularly relevant for Allura.
 cache_dir = %(here)s/data
 
 ; Cache Neighborhood objects for N seconds (speeds up requests).
@@ -395,11 +396,6 @@ forgemail.url = http://localhost:8080
 ; set this to "false" if you are deploying to production and want performance improvements
 auto_reload_templates = true
 
-; WARNING: *THE LINE BELOW MUST BE UNCOMMENTED ON A PRODUCTION ENVIRONMENT*
-; Debug mode will enable the interactive debugging tool, allowing ANYONE to
-; execute malicious code after an exception is raised.
-;set debug = false
-
 ; How frequently users can send messages
 user_message.time_interval = 3600
 user_message.max_messages = 20
@@ -457,29 +453,6 @@ short_url.url_pattern = {base_url}/{nbhd}/{project}/{mount_point}/{short_name}
 userstats.count_lines_of_code = true
 
 
-; Setup for tool testing
-[app:tool_test]
-use = egg:Allura
-override_root=basetest_project_root ; TurboGears will use controllers/basetest_project_root.py as root controller
-full_stack = true
-
-cache_dir = %(here)s/data
-beaker.session.key = allura
-beaker.session.type = cookie
-beaker.session.validate_key = 714bfe3612c42390726f
-
-; Ming setup
-ming.main.uri = mongo://127.0.0.1:27017/allura:test
-
-; Forgemail server
-forgemail.host = 0.0.0.0
-forgemail.port = 8825
-forgemail.domain = .in.sf.net
-forgemail.return_path = noreply@sourceforge.net
-forgemail.url = http://localhost:8080
-
-auth.method = local
-registration.method = local
 
 ; setup for the taskd background daemon request controller
 [app:task]

http://git-wip-us.apache.org/repos/asf/allura/blob/97eb3ac0/Allura/test.ini
----------------------------------------------------------------------
diff --git a/Allura/test.ini b/Allura/test.ini
index ecf1639..101a427 100644
--- a/Allura/test.ini
+++ b/Allura/test.ini
@@ -15,18 +15,13 @@
 #       specific language governing permissions and limitations
 #       under the License.
 #
-# allura - TurboGears 2 testing environment configuration
+# allura - testing configuration
 #
-# The %(here)s variable will be replaced with the parent directory of this file
 #
 [DEFAULT]
 debug = false
-# make sure, since this extends development.ini
-set debug = false
-# Uncomment and replace with the address which should receive any error reports
-# email_to = you@yourdomain.com
+
 smtp_server = localhost
-error_email_from = paste@localhost
 
 [server:main]
 use = egg:Paste#http
@@ -34,24 +29,11 @@ host = 0.0.0.0
 port = 5000
 
 [app:main]
-use = config:development.ini#tool_test
-db_prefix = test_
+use = config:development.ini#main
+override_root=basetest_project_root ; TurboGears will use controllers/basetest_project_root.py as root controller
 disable_template_overrides = True
 
-site_name = Allura
-base_url = http://localhost
-domain = localhost
-
-mediawikiimporter.db_config_prefix = hostedapps.db.
-mediawikiimporter.attachments_dir_prefix = /nfs/mediawiki-attachments/
-mediawikiimporter.db_name_template = p_%s_mediawiki
-hostedapps.db.host = localhost
-hostedapps.db.port = 3306
-hostedapps.db.user = user
-hostedapps.db.password = password
-
-# Use test MongoDB DB server
-# ming.main.master = mongo://127.0.0.1:27018/allura
+# Use in-memory MongoDB
 ming.main.uri = mim:///allura
 ming.project.uri = mim:///project-data
 ming.task.uri = mim:///task
@@ -68,15 +50,8 @@ activitystream.recording.enabled = true
 activitystream.enabled = true
 
 solr.mock = true
-amqp.mock = true
 smtp.mock = true
 
-# Forgemail server
-forgemail.host = 0.0.0.0
-forgemail.port = 8825
-forgemail.domain = .in.localhost
-forgemail.url = http://localhost:8080
-forgemail.return_path = noreply@localhost
 
 load_test_data = true
 cache_test_data = false
@@ -123,9 +98,6 @@ bulk_export_download_instructions = Sample instructions for {project}
 
 support_tool_choices = wiki tickets discussion
 
-#stats.sample_rate = 0
-
-short_url.url_pattern = {base_url}/{nbhd}/{project}/{mount_point}/{short_name}
 
 # markdown text longer than max length will not be converted to html
 # tests expect max length of 40000
@@ -151,15 +123,6 @@ user_prefs_storage.ldap.fields.display_name = cn
 auth.allow_user_to_disable_account = true
 auth.allow_edit_prefs = true
 
-[app:main_with_amqp]
-use = main
-# Use test RabbitMQ vhost
-amqp.mock = false
-amqp.hostname = localhost
-amqp.port = 5672
-amqp.userid = testuser
-amqp.password = testpw
-amqp.vhost = vhost_testing
 
 
 # Add additional test specific configuration options as necessary.