card 1.101.1 → 1.101.6
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +4 -4
- data/VERSION +1 -1
- data/config/i18n-tasks.yml +0 -5
- data/config/initializers/01_core_extensions/array.rb +2 -1
- data/config/initializers/01_core_extensions/hash.rb +1 -0
- data/config/initializers/01_core_extensions/object.rb +15 -11
- data/config/initializers/02_patches/active_job.rb +1 -1
- data/config/initializers/02_patches/active_record.rb +2 -4
- data/config/initializers/02_patches/better_errors.rb +1 -3
- data/config/initializers/02_patches/kaminari.rb +2 -2
- data/config/initializers/deck_config.rb +1 -1
- data/config/initializers/inflections.rb +1 -0
- data/config/initializers/internationalization.rb +23 -21
- data/config/initializers/mime_types.rb +1 -0
- data/config/initializers/notification.rb +1 -0
- data/config/initializers/patches.rb +6 -5
- data/config/locales/en.yml +138 -528
- data/db/migrate/20110511221913_require_earlier_migrations.rb +1 -0
- data/db/migrate/20121111025347_require_1_10_migrations.rb +1 -0
- data/db/migrate/20121118114000_split_link_type.rb +1 -0
- data/db/migrate/20121118115000_update_link_type.rb +1 -0
- data/db/migrate/20130106052640_table_cleanup.rb +2 -2
- data/db/migrate/20130109015336_trunk_left.rb +1 -0
- data/db/migrate/20130411210957_update_codenames.rb +1 -0
- data/db/migrate/20140822073704_create_new_revision_tables.rb +1 -0
- data/db/migrate/20141001105348_move_revisions_to_actions.rb +9 -3
- data/db/migrate/20141216053032_better_index_names.rb +9 -6
- data/db/migrate/20170908114442_create_delayed_jobs.rb +1 -1
- data/db/migrate/20170908114452_increase_text_size_for_delayed_jobs.rb +1 -1
- data/db/migrate/20180514152037_add_card_virtuals_table.rb +1 -1
- data/db/migrate/20200805200729_add_unique_pair_indeces.rb +35 -1
- data/db/migrate_core_cards/20120611203506_rails_inflection_updates.rb +3 -2
- data/db/migrate_core_cards/20130411191151_renaming_for_menu.rb +9 -9
- data/db/migrate_core_cards/20130419215612_import_help_text.rb +3 -2
- data/db/migrate_core_cards/20130823192433_add_style_cards.rb +5 -5
- data/db/migrate_core_cards/20130910183318_move_styles_to_content.rb +3 -2
- data/db/migrate_core_cards/20130920291703_update_stylesheets.rb +2 -4
- data/db/migrate_core_cards/20131016172445_common_css_patch.rb +1 -3
- data/db/migrate_core_cards/20140110193325_reset_account_request_type.rb +1 -3
- data/db/migrate_core_cards/20140307231621_user_data_to_cards.rb +12 -8
- data/db/migrate_core_cards/20140317035504_account_requests_to_signups.rb +2 -4
- data/db/migrate_core_cards/20140512155840_add_script_cards.rb +16 -9
- data/db/migrate_core_cards/20140629222005_add_email_cards.rb +19 -11
- data/db/migrate_core_cards/20140725180118_config_card_updates.rb +1 -1
- data/db/migrate_core_cards/20141115034214_config_descriptions_etc.rb +1 -1
- data/db/migrate_core_cards/20141119001955_make_symlinks_relative.rb +1 -1
- data/db/migrate_core_cards/20141204061304_watchers_to_following.rb +2 -0
- data/db/migrate_core_cards/20141216155251_add_more_following_cards.rb +4 -2
- data/db/migrate_core_cards/20150202143810_import_bootstrap_layout.rb +2 -2
- data/db/migrate_core_cards/20150220134731_following_to_follow_rule.rb +3 -4
- data/db/migrate_core_cards/20150317162412_bootstrap_themes.rb +8 -4
- data/db/migrate_core_cards/20150326205655_bootswatch_themes.rb +14 -7
- data/db/migrate_core_cards/20150429090551_search_card_context.rb +6 -4
- data/db/migrate_core_cards/20150508212032_menu_compatibility.rb +4 -2
- data/db/migrate_core_cards/20150510031118_fix_skin_codenames.rb +2 -1
- data/db/migrate_core_cards/20150601133433_add_recent_setting_session_card.rb +3 -3
- data/db/migrate_core_cards/20150610171702_add_debugger_session_card.rb +2 -1
- data/db/migrate_core_cards/20150610180019_add_recaptcha_key_and_admin_info_cards.rb +4 -3
- data/db/migrate_core_cards/20150724123438_update_file_and_image_cards.rb +6 -2
- data/db/migrate_core_cards/20150807205221_create_references_for_search_cards.rb +1 -1
- data/db/migrate_core_cards/20150824135418_update_file_history.rb +2 -0
- data/db/migrate_core_cards/20160804112510_reorganize_scripts.rb +1 -1
- data/db/migrate_core_cards/20160811115836_rename_stats_to_admin.rb +1 -0
- data/db/migrate_core_cards/20160914132636_fix_mod_files.rb +2 -0
- data/db/migrate_core_cards/20161102202156_tweak_recaptcha_setting_cards.rb +6 -6
- data/db/migrate_core_cards/20161103154836_update_keys.rb +2 -1
- data/db/migrate_core_cards/20170209132834_email_test_context.rb +2 -0
- data/db/migrate_core_cards/20170314175313_add_notification_event_card.rb +3 -3
- data/db/migrate_core_cards/20170515101262_add_advanced_edit_cards.rb +1 -1
- data/db/migrate_core_cards/20170608200649_add_input_options_codename.rb +1 -1
- data/db/migrate_core_cards/20180712042655_head_rule.rb +3 -4
- data/db/migrate_core_cards/20180905061537_migrate_layouts.rb +4 -4
- data/db/migrate_core_cards/20181120200937_update_layout.rb +1 -1
- data/db/migrate_core_cards/20190320091257_upgrade_recaptcha_to_v3.rb +7 -7
- data/db/migrate_core_cards/20190424100531_update_credit_image.rb +1 -0
- data/db/migrate_core_cards/20190502130029_add_shark_and_help_desk_role.rb +15 -14
- data/db/migrate_core_cards/20190503122739_update_pristine_data.rb +1 -1
- data/db/migrate_core_cards/20190625153616_pointer_overhaul.rb +9 -5
- data/db/migrate_core_cards/20190718140126_add_guides.rb +3 -3
- data/db/migrate_core_cards/20190822093633_move_help_text_to_code.rb +1 -2
- data/db/migrate_core_cards/20190823220018_cleanup_for_decko_1_0.rb +1 -1
- data/db/migrate_core_cards/20190829093961_cardtype_grouping.rb +4 -4
- data/db/migrate_core_cards/20190902193208_input_type.rb +1 -3
- data/db/migrate_core_cards/20190909104250_add_cardtype_input_types.rb +2 -2
- data/db/migrate_core_cards/20191028135243_add_link_editor_to_tiny_mce_config.rb +1 -0
- data/db/migrate_core_cards/20191115160748_history_cleanup.rb +0 -1
- data/db/migrate_core_cards/20191118145629_codename_fixes.rb +1 -2
- data/db/migrate_core_cards/20200821231558_add_nest_list_type.rb +1 -1
- data/db/seed/new/card_actions.yml +2153 -2145
- data/db/seed/new/card_acts.yml +3 -3
- data/db/seed/new/card_references.yml +900 -858
- data/db/seed/new/cards.yml +4869 -4848
- data/db/seed/new/schema_migrations_deck_cards.yml +2 -0
- data/db/seed/test/fixtures/card_actions.yml +3563 -3547
- data/db/seed/test/fixtures/card_acts.yml +675 -675
- data/db/seed/test/fixtures/card_changes.yml +103 -103
- data/db/seed/test/fixtures/card_references.yml +2165 -2123
- data/db/seed/test/fixtures/cards.yml +7862 -7751
- data/db/seed/test/fixtures/rails.gif +0 -0
- data/db/seed/test/fixtures/schema_migrations_deck_cards.yml +2 -0
- data/db/test_seed.rb +33 -34
- data/lib/card.rb +16 -2
- data/lib/card/auth.rb +5 -2
- data/lib/card/auth/current.rb +39 -100
- data/lib/card/auth/proxy.rb +36 -16
- data/lib/card/auth/token.rb +8 -2
- data/lib/card/cache.rb +2 -1
- data/lib/card/cache/all.rb +88 -0
- data/lib/card/cache/card_class.rb +44 -0
- data/lib/card/cache/persistent.rb +3 -34
- data/lib/card/cache/persistent_class.rb +28 -0
- data/lib/card/codename.rb +3 -4
- data/lib/card/content.rb +20 -10
- data/lib/card/content/all.rb +59 -0
- data/lib/card/content/chunk.rb +1 -1
- data/lib/card/content/clean.rb +4 -3
- data/lib/card/content/diff.rb +3 -2
- data/lib/card/content/diff/l_c_s/processor.rb +1 -1
- data/lib/card/content/diff/result.rb +1 -125
- data/lib/card/content/diff/summary.rb +136 -0
- data/lib/card/content/parser.rb +2 -2
- data/lib/card/content/truncate.rb +6 -6
- data/lib/card/director.rb +1 -1
- data/lib/card/director/act_direction.rb +4 -0
- data/lib/card/director/all.rb +61 -0
- data/lib/card/director/card_class.rb +18 -0
- data/lib/card/director/card_methods.rb +1 -0
- data/lib/card/director/event_delay.rb +4 -6
- data/lib/card/director/phases.rb +0 -1
- data/lib/card/director/run.rb +2 -0
- data/lib/card/director/stages.rb +3 -2
- data/lib/card/dirty.rb +13 -3
- data/lib/card/env/location.rb +4 -3
- data/lib/card/env/success.rb +46 -103
- data/lib/card/env/success/target.rb +73 -0
- data/lib/card/error.rb +1 -2
- data/lib/card/fetch.rb +7 -4
- data/lib/card/fetch/all.rb +33 -0
- data/lib/card/fetch/card_class.rb +155 -0
- data/lib/card/fetch/results.rb +9 -0
- data/lib/card/fetch/retrieve.rb +2 -0
- data/lib/card/fetch/store.rb +1 -0
- data/lib/card/format.rb +1 -2
- data/lib/card/format/content.rb +1 -3
- data/lib/card/format/error.rb +8 -4
- data/lib/card/format/method_delegation.rb +10 -2
- data/lib/card/format/nest.rb +3 -2
- data/lib/card/format/nest/fetch.rb +3 -2
- data/lib/card/format/nesting/mode.rb +1 -1
- data/lib/card/format/nesting/subformat.rb +2 -1
- data/lib/card/format/render.rb +2 -2
- data/lib/card/format/wrapper.rb +1 -1
- data/lib/card/lexicon.rb +5 -4
- data/lib/card/mailer.rb +15 -12
- data/lib/card/mark.rb +17 -15
- data/lib/card/model/save_helper.rb +3 -3
- data/lib/card/name.rb +10 -9
- data/lib/card/name/all.rb +11 -0
- data/lib/card/name/all/descendants.rb +7 -5
- data/lib/card/name/card_class.rb +28 -0
- data/lib/card/name/fields_and_traits.rb +4 -2
- data/lib/card/name/name_variants.rb +0 -1
- data/lib/card/query.rb +17 -17
- data/lib/card/query/act_query.rb +2 -2
- data/lib/card/query/action_query.rb +1 -1
- data/lib/card/query/card_query/conjunctions.rb +1 -1
- data/lib/card/query/card_query/interpretation.rb +1 -0
- data/lib/card/query/card_query/match_attributes.rb +2 -1
- data/lib/card/query/card_query/normalization.rb +1 -0
- data/lib/card/query/card_query/reference_attributes.rb +2 -2
- data/lib/card/query/card_query/relational_attributes.rb +2 -2
- data/lib/card/query/join.rb +1 -1
- data/lib/card/query/value/match_value.rb +1 -0
- data/lib/card/reference/all.rb +136 -0
- data/lib/card/rule/all.rb +76 -0
- data/lib/card/rule/cache.rb +2 -0
- data/lib/card/set/advanced_api.rb +4 -4
- data/lib/card/set/event.rb +10 -6
- data/lib/card/set/event/all.rb +101 -0
- data/lib/card/set/event/delayed_event.rb +6 -6
- data/lib/card/set/event/options.rb +1 -0
- data/lib/card/set/event/skip_and_trigger.rb +89 -0
- data/lib/card/set/format/abstract_format/view_definition.rb +1 -0
- data/lib/card/set/format/abstract_format/view_opts.rb +1 -0
- data/lib/card/set/i18n_scope.rb +18 -13
- data/lib/card/set/inheritance.rb +8 -6
- data/lib/card/set/loader.rb +24 -13
- data/lib/card/set/pattern/all.rb +63 -0
- data/lib/card/set/pattern/base.rb +4 -74
- data/lib/card/set/pattern/class_methods.rb +75 -0
- data/lib/card/set/required_field.rb +4 -1
- data/lib/card/setting.rb +13 -12
- data/lib/card/subcards.rb +3 -4
- data/lib/card/subcards/all.rb +103 -0
- data/lib/card/tasks/card/file_card_creator/abstract_file_card/ruby_file.rb +1 -1
- data/lib/card/tasks/card/file_card_creator/output_helper.rb +2 -4
- data/lib/card/tasks/card/migrate.rake +2 -2
- data/lib/card/view/cache.rb +6 -8
- data/lib/card/view/cache/cache_action.rb +1 -2
- data/lib/card/view/cache/stub.rb +1 -1
- data/lib/card/view/options.rb +3 -3
- data/lib/card/view/permission.rb +1 -0
- data/lib/cardio.rb +1 -1
- data/lib/cardio/migration.rb +1 -1
- data/lib/cardio/migration/deck_structure.rb +2 -4
- data/lib/cardio/migration/import.rb +3 -3
- data/lib/cardio/migration/import/import_data.rb +1 -0
- data/lib/cardio/mod.rb +2 -1
- data/lib/cardio/mod/dirs.rb +2 -2
- data/lib/cardio/mod/load_strategy.rb +2 -4
- data/lib/cardio/mod/loader/set_loader.rb +2 -1
- data/lib/cardio/mod/loader/set_pattern_loader.rb +0 -1
- data/lib/cardio/mod/module_template.rb +1 -0
- data/lib/cardio/modfiles.rb +2 -4
- data/lib/cardio/schema.rb +2 -4
- data/lib/cardio/utils.rb +9 -0
- data/lib/generators/card/format/format_generator.rb +1 -1
- data/lib/generators/card/migration/migration_generator.rb +2 -1
- data/lib/generators/card/mod/mod_generator.rb +3 -2
- data/lib/generators/card/set/set_generator.rb +3 -3
- data/lib/generators/card/template/template_generator.rb +1 -1
- data/mod/admin/set/self/admin.rb +6 -3
- data/mod/admin/set/self/admin_info.rb +3 -8
- data/mod/admin/spec/set/self/admin_spec.rb +4 -4
- data/mod/core/set/all/abort.rb +5 -5
- data/mod/core/set/all/assign_attributes.rb +5 -8
- data/mod/core/set/all/autoname.rb +17 -0
- data/mod/core/set/all/codename.rb +3 -2
- data/mod/core/set/all/collection.rb +4 -6
- data/mod/core/set/all/content.rb +25 -138
- data/mod/core/set/all/debug.rb +7 -10
- data/mod/core/set/all/initialize.rb +4 -0
- data/mod/core/set/all/name_events.rb +78 -60
- data/mod/core/set/all/reference_events.rb +69 -0
- data/mod/core/set/all/states.rb +5 -5
- data/mod/core/set/all/subcards.rb +1 -101
- data/mod/core/set/all/trash.rb +20 -14
- data/mod/core/set/all/type.rb +11 -11
- data/mod/core/set/all/utils.rb +4 -1
- data/mod/{admin → core}/set/self/trash.rb +3 -2
- data/mod/core/set/self/version.rb +0 -4
- data/mod/core/set/type/cardtype.rb +3 -3
- data/mod/core/set_pattern/06_rule.rb +1 -1
- data/mod/core/spec/set/all/assign_attributes_spec.rb +10 -9
- data/mod/core/spec/set/all/{rules2_spec.rb → clean_me_spec.rb} +19 -4
- data/mod/core/spec/set/all/collection_spec.rb +1 -1
- data/mod/core/spec/set/all/export_spec.rb +1 -0
- data/mod/core/spec/set/all/initialize_spec.rb +11 -11
- data/mod/core/spec/set/all/name_events_spec.rb +204 -0
- data/mod/{admin → core}/spec/set/self/trash_spec.rb +0 -0
- data/tmpsets/set/mod001-admin/self/admin.rb +6 -3
- data/tmpsets/set/mod001-admin/self/admin_info.rb +3 -8
- data/tmpsets/set/mod002-core/all/abort.rb +8 -8
- data/tmpsets/set/mod002-core/all/assign_attributes.rb +12 -28
- data/tmpsets/set/mod002-core/all/autoname.rb +26 -0
- data/tmpsets/set/mod002-core/all/codename.rb +3 -2
- data/tmpsets/set/mod002-core/all/collection.rb +4 -6
- data/tmpsets/set/mod002-core/all/content.rb +55 -99
- data/tmpsets/set/mod002-core/all/contextual_content.rb +2 -4
- data/tmpsets/set/mod002-core/all/debug.rb +8 -10
- data/tmpsets/set/mod002-core/all/initialize.rb +13 -9
- data/tmpsets/set/mod002-core/all/name_events.rb +78 -58
- data/tmpsets/set/mod002-core/all/reference_events.rb +78 -0
- data/tmpsets/set/mod002-core/all/states.rb +4 -4
- data/tmpsets/set/mod002-core/all/subcards.rb +1 -101
- data/tmpsets/set/mod002-core/all/trash.rb +20 -14
- data/tmpsets/set/mod002-core/all/type.rb +11 -11
- data/tmpsets/set/mod002-core/all/utils.rb +4 -1
- data/tmpsets/set/mod002-core/right/autoname.rb +12 -0
- data/tmpsets/set/{mod003-settings → mod002-core}/self/autoname.rb +2 -2
- data/tmpsets/set/{mod001-admin → mod002-core}/self/trash.rb +5 -4
- data/tmpsets/set/mod002-core/self/version.rb +0 -4
- data/tmpsets/set/mod002-core/type/cardtype.rb +37 -0
- data/tmpsets/set/{mod005-card-mod-email → mod004-card-mod-email}/abstract/email_field.rb +1 -2
- data/tmpsets/set/{mod005-card-mod-email → mod004-card-mod-email}/abstract/test_context.rb +1 -0
- data/tmpsets/set/{mod005-card-mod-email → mod004-card-mod-email}/all/email_html.rb +0 -0
- data/tmpsets/set/{mod005-card-mod-email → mod004-card-mod-email}/all/email_text.rb +0 -1
- data/tmpsets/set/{mod005-card-mod-email → mod004-card-mod-email}/right/bcc.rb +0 -0
- data/tmpsets/set/{mod005-card-mod-email → mod004-card-mod-email}/right/cc.rb +0 -0
- data/tmpsets/set/{mod005-card-mod-email → mod004-card-mod-email}/right/from.rb +0 -0
- data/tmpsets/set/{mod005-card-mod-email → mod004-card-mod-email}/right/html_message.rb +1 -0
- data/tmpsets/set/{mod005-card-mod-email → mod004-card-mod-email}/right/subject.rb +0 -0
- data/tmpsets/set/{mod005-card-mod-email → mod004-card-mod-email}/right/text_message.rb +0 -0
- data/tmpsets/set/{mod005-card-mod-email → mod004-card-mod-email}/right/to.rb +0 -0
- data/tmpsets/set/{mod005-card-mod-email → mod004-card-mod-email}/type/email_template.rb +4 -3
- data/tmpsets/set/{mod005-card-mod-email → mod004-card-mod-email}/type/email_template/email_config.rb +3 -1
- data/tmpsets/set/{mod006-card-mod-collection → mod005-card-mod-collection}/abstract/items.rb +5 -1
- data/tmpsets/set/{mod006-card-mod-collection → mod005-card-mod-collection}/abstract/paging.rb +1 -0
- data/tmpsets/set/{mod006-card-mod-collection → mod005-card-mod-collection}/abstract/paging/paging_links.rb +1 -0
- data/tmpsets/set/{mod006-card-mod-collection → mod005-card-mod-collection}/abstract/paging/paging_views.rb +1 -0
- data/tmpsets/set/{mod006-card-mod-collection → mod005-card-mod-collection}/all/extended.rb +2 -1
- data/tmpsets/set/{mod006-card-mod-collection → mod005-card-mod-collection}/all/item.rb +7 -1
- data/tmpsets/set/{mod007-card-mod-content → mod006-card-mod-content}/abstract/code_file.rb +0 -1
- data/tmpsets/set/{mod007-card-mod-content → mod006-card-mod-content}/abstract/haml_file.rb +0 -1
- data/tmpsets/set/{mod007-card-mod-content → mod006-card-mod-content}/abstract/lock.rb +1 -0
- data/tmpsets/set/{mod007-card-mod-content → mod006-card-mod-content}/abstract/templated_nests.rb +0 -0
- data/tmpsets/set/{mod007-card-mod-content → mod006-card-mod-content}/abstract/vendor_code_file.rb +0 -0
- data/tmpsets/set/{mod007-card-mod-content → mod006-card-mod-content}/all/chunk.rb +8 -8
- data/tmpsets/set/{mod007-card-mod-content → mod006-card-mod-content}/all/templating.rb +1 -1
- data/tmpsets/set/{mod007-card-mod-content → mod006-card-mod-content}/right/default.rb +0 -0
- data/tmpsets/set/{mod007-card-mod-content → mod006-card-mod-content}/right/structure.rb +5 -1
- data/tmpsets/set/{mod007-card-mod-content → mod006-card-mod-content}/self/default.rb +0 -0
- data/tmpsets/set/{mod007-card-mod-content → mod006-card-mod-content}/self/structure.rb +0 -0
- data/tmpsets/set/{mod008-card-mod-format → mod007-card-mod-format}/all/active_card.rb +1 -2
- data/tmpsets/set/{mod008-card-mod-format → mod007-card-mod-format}/all/base.rb +3 -1
- data/tmpsets/set/{mod008-card-mod-format → mod007-card-mod-format}/all/css.rb +0 -1
- data/tmpsets/set/{mod008-card-mod-format → mod007-card-mod-format}/all/csv.rb +2 -1
- data/tmpsets/set/mod007-card-mod-format/all/demo.rb +45 -0
- data/tmpsets/set/{mod008-card-mod-format → mod007-card-mod-format}/all/error.rb +12 -19
- data/tmpsets/set/{mod008-card-mod-format → mod007-card-mod-format}/all/export.rb +2 -0
- data/tmpsets/set/{mod008-card-mod-format → mod007-card-mod-format}/all/file.rb +0 -0
- data/tmpsets/set/{mod008-card-mod-format → mod007-card-mod-format}/all/frame.rb +6 -10
- data/tmpsets/set/{mod008-card-mod-format → mod007-card-mod-format}/all/haml.rb +0 -0
- data/tmpsets/set/{mod008-card-mod-format → mod007-card-mod-format}/all/head.rb +5 -1
- data/tmpsets/set/{mod008-card-mod-format → mod007-card-mod-format}/all/header.rb +0 -0
- data/tmpsets/set/{mod008-card-mod-format → mod007-card-mod-format}/all/html_content.rb +2 -1
- data/tmpsets/set/{mod008-card-mod-format → mod007-card-mod-format}/all/html_error.rb +25 -10
- data/tmpsets/set/{mod008-card-mod-format → mod007-card-mod-format}/all/html_show.rb +0 -0
- data/tmpsets/set/{mod008-card-mod-format → mod007-card-mod-format}/all/html_title.rb +0 -0
- data/tmpsets/set/{mod008-card-mod-format → mod007-card-mod-format}/all/html_wrapper.rb +13 -8
- data/tmpsets/set/{mod008-card-mod-format → mod007-card-mod-format}/all/js.rb +0 -1
- data/tmpsets/set/{mod008-card-mod-format → mod007-card-mod-format}/all/json.rb +1 -2
- data/tmpsets/set/{mod008-card-mod-format → mod007-card-mod-format}/all/links.rb +5 -4
- data/tmpsets/set/{mod008-card-mod-format → mod007-card-mod-format}/all/menu.rb +1 -1
- data/tmpsets/set/{mod008-card-mod-format → mod007-card-mod-format}/all/path.rb +1 -0
- data/tmpsets/set/{mod008-card-mod-format → mod007-card-mod-format}/all/rich_html.rb +12 -0
- data/tmpsets/set/{mod008-card-mod-format → mod007-card-mod-format}/all/rss.rb +3 -2
- data/tmpsets/set/{mod008-card-mod-format → mod007-card-mod-format}/all/text.rb +0 -1
- data/tmpsets/set/{mod008-card-mod-format → mod007-card-mod-format}/self/home.rb +0 -0
- data/tmpsets/set/mod007-card-mod-format/type/cardtype.rb +98 -0
- data/tmpsets/set/{mod008-card-mod-format → mod007-card-mod-format}/type/html.rb +0 -0
- data/tmpsets/set/{mod008-card-mod-format → mod007-card-mod-format}/type/json.rb +1 -1
- data/tmpsets/set/{mod008-card-mod-format → mod007-card-mod-format}/type/number.rb +4 -2
- data/tmpsets/set/{mod008-card-mod-format → mod007-card-mod-format}/type/phrase.rb +0 -0
- data/tmpsets/set/{mod008-card-mod-format → mod007-card-mod-format}/type/plain_text.rb +0 -0
- data/tmpsets/set/{mod008-card-mod-format → mod007-card-mod-format}/type/toggle.rb +2 -2
- data/tmpsets/set/{mod008-card-mod-format → mod007-card-mod-format}/type/uri.rb +0 -0
- data/tmpsets/set/{mod009-card-mod-list → mod008-card-mod-list}/abstract/01_pointer.rb +0 -0
- data/tmpsets/set/{mod009-card-mod-list → mod008-card-mod-list}/abstract/01_pointer/events.rb +0 -0
- data/tmpsets/set/{mod009-card-mod-list → mod008-card-mod-list}/abstract/01_pointer/html_views.rb +1 -2
- data/tmpsets/set/{mod009-card-mod-list → mod008-card-mod-list}/abstract/01_pointer/html_views/filter.rb +1 -0
- data/tmpsets/set/{mod009-card-mod-list → mod008-card-mod-list}/abstract/01_pointer/options_api.rb +0 -0
- data/tmpsets/set/{mod009-card-mod-list → mod008-card-mod-list}/abstract/01_pointer/other_views.rb +1 -0
- data/tmpsets/set/{mod009-card-mod-list → mod008-card-mod-list}/abstract/code_pointer.rb +0 -0
- data/tmpsets/set/{mod009-card-mod-list → mod008-card-mod-list}/abstract/id_pointer.rb +1 -1
- data/tmpsets/set/{mod009-card-mod-list → mod008-card-mod-list}/all/supports_content_options.rb +0 -0
- data/tmpsets/set/{mod009-card-mod-list → mod008-card-mod-list}/right/content_option_view.rb +0 -0
- data/tmpsets/set/{mod009-card-mod-list → mod008-card-mod-list}/right/content_options.rb +0 -0
- data/tmpsets/set/{mod009-card-mod-list → mod008-card-mod-list}/self/content_option_view.rb +0 -0
- data/tmpsets/set/{mod009-card-mod-list → mod008-card-mod-list}/self/content_options.rb +0 -0
- data/tmpsets/set/{mod009-card-mod-list → mod008-card-mod-list}/self/input_options.rb +1 -0
- data/tmpsets/set/{mod009-card-mod-list → mod008-card-mod-list}/type/link_list.rb +0 -0
- data/tmpsets/set/{mod009-card-mod-list → mod008-card-mod-list}/type/list.rb +0 -0
- data/tmpsets/set/{mod009-card-mod-list → mod008-card-mod-list}/type/nest_list.rb +1 -1
- data/tmpsets/set/{mod009-card-mod-list → mod008-card-mod-list}/type/pointer.rb +0 -0
- data/tmpsets/set/{mod010-card-mod-permissions → mod009-card-mod-permissions}/abstract/permission.rb +3 -2
- data/tmpsets/set/{mod010-card-mod-permissions → mod009-card-mod-permissions}/all/permissions.rb +11 -7
- data/tmpsets/set/{mod010-card-mod-permissions → mod009-card-mod-permissions}/all/update_read_rules.rb +2 -3
- data/tmpsets/set/{mod010-card-mod-permissions → mod009-card-mod-permissions}/right/create.rb +0 -0
- data/tmpsets/set/{mod010-card-mod-permissions → mod009-card-mod-permissions}/right/delete.rb +0 -0
- data/tmpsets/set/{mod010-card-mod-permissions → mod009-card-mod-permissions}/right/read.rb +3 -5
- data/tmpsets/set/{mod010-card-mod-permissions → mod009-card-mod-permissions}/right/update.rb +0 -0
- data/tmpsets/set/{mod010-card-mod-permissions → mod009-card-mod-permissions}/self/create.rb +0 -0
- data/tmpsets/set/{mod010-card-mod-permissions → mod009-card-mod-permissions}/self/delete.rb +0 -0
- data/tmpsets/set/{mod010-card-mod-permissions → mod009-card-mod-permissions}/self/read.rb +0 -0
- data/tmpsets/set/{mod010-card-mod-permissions → mod009-card-mod-permissions}/self/update.rb +0 -0
- data/tmpsets/set/{mod011-card-mod-account → mod010-card-mod-account}/abstract/account_field.rb +5 -0
- data/tmpsets/set/{mod011-card-mod-account → mod010-card-mod-account}/abstract/accountable.rb +5 -1
- data/tmpsets/set/{mod011-card-mod-account → mod010-card-mod-account}/all/account.rb +16 -7
- data/tmpsets/set/{mod011-card-mod-account → mod010-card-mod-account}/right/account.rb +3 -8
- data/tmpsets/set/{mod011-card-mod-account → mod010-card-mod-account}/right/account/events.rb +2 -2
- data/tmpsets/set/{mod011-card-mod-account → mod010-card-mod-account}/right/account/views.rb +0 -0
- data/tmpsets/set/{mod011-card-mod-account → mod010-card-mod-account}/right/email.rb +5 -4
- data/tmpsets/set/{mod011-card-mod-account → mod010-card-mod-account}/right/password.rb +4 -3
- data/tmpsets/set/{mod011-card-mod-account → mod010-card-mod-account}/right/roles.rb +2 -2
- data/tmpsets/set/{mod011-card-mod-account → mod010-card-mod-account}/right/salt.rb +1 -1
- data/tmpsets/set/{mod011-card-mod-account → mod010-card-mod-account}/right/status.rb +1 -1
- data/tmpsets/set/{mod011-card-mod-account → mod010-card-mod-account}/self/signin.rb +37 -50
- data/tmpsets/set/{mod011-card-mod-account → mod010-card-mod-account}/type/role.rb +0 -0
- data/tmpsets/set/{mod011-card-mod-account → mod010-card-mod-account}/type/signup.rb +0 -0
- data/tmpsets/set/{mod011-card-mod-account → mod010-card-mod-account}/type/signup/views.rb +7 -2
- data/tmpsets/set/{mod011-card-mod-account → mod010-card-mod-account}/type/user.rb +1 -1
- data/tmpsets/set/{mod011-card-mod-account → mod010-card-mod-account}/type_plus_right/user/email.rb +0 -0
- data/tmpsets/set/{mod012-card-mod-edit → mod011-card-mod-edit}/all/bridge.rb +3 -3
- data/tmpsets/set/{mod012-card-mod-edit → mod011-card-mod-edit}/all/bridge/bridge_pills.rb +0 -0
- data/tmpsets/set/{mod012-card-mod-edit → mod011-card-mod-edit}/all/bridge/follow_section.rb +0 -0
- data/tmpsets/set/{mod012-card-mod-edit → mod011-card-mod-edit}/all/bridge/related_section.rb +2 -2
- data/tmpsets/set/{mod012-card-mod-edit → mod011-card-mod-edit}/all/bridge/tab_views.rb +0 -0
- data/tmpsets/set/{mod012-card-mod-edit → mod011-card-mod-edit}/all/bridge/tab_visibility.rb +10 -5
- data/tmpsets/set/{mod012-card-mod-edit → mod011-card-mod-edit}/all/edit_content.rb +0 -0
- data/tmpsets/set/{mod012-card-mod-edit → mod011-card-mod-edit}/all/edit_inline.rb +0 -0
- data/tmpsets/set/{mod012-card-mod-edit → mod011-card-mod-edit}/all/edit_name.rb +18 -20
- data/tmpsets/set/{mod012-card-mod-edit → mod011-card-mod-edit}/all/edit_type.rb +52 -33
- data/tmpsets/set/{mod012-card-mod-edit → mod011-card-mod-edit}/all/editing.rb +0 -0
- data/tmpsets/set/{mod012-card-mod-edit → mod011-card-mod-edit}/all/editor.rb +3 -5
- data/tmpsets/set/{mod012-card-mod-edit → mod011-card-mod-edit}/all/form.rb +14 -11
- data/tmpsets/set/{mod012-card-mod-edit → mod011-card-mod-edit}/all/form_buttons.rb +11 -2
- data/tmpsets/set/{mod012-card-mod-edit → mod011-card-mod-edit}/all/form_elements.rb +1 -0
- data/tmpsets/set/{mod012-card-mod-edit → mod011-card-mod-edit}/all/formgroup.rb +0 -0
- data/tmpsets/set/{mod012-card-mod-edit → mod011-card-mod-edit}/all/new.rb +2 -2
- data/tmpsets/set/{mod012-card-mod-edit → mod011-card-mod-edit}/all/overlay_guide.rb +0 -0
- data/tmpsets/set/{mod012-card-mod-edit → mod011-card-mod-edit}/all/template_nest.rb +0 -0
- data/tmpsets/set/{mod012-card-mod-edit → mod011-card-mod-edit}/right/input_type.rb +0 -0
- data/tmpsets/set/{mod012-card-mod-edit → mod011-card-mod-edit}/self/input_type.rb +0 -0
- data/tmpsets/set/{mod012-card-mod-edit → mod011-card-mod-edit}/type/list.rb +0 -0
- data/tmpsets/set/{mod012-card-mod-edit → mod011-card-mod-edit}/type/plain_text.rb +0 -0
- data/tmpsets/set/{mod012-card-mod-edit → mod011-card-mod-edit}/type/pointer.rb +0 -0
- data/tmpsets/set/{mod013-card-mod-history → mod012-card-mod-history}/all/history.rb +2 -1
- data/tmpsets/set/{mod013-card-mod-history → mod012-card-mod-history}/all/history/act_listing.rb +9 -6
- data/tmpsets/set/{mod013-card-mod-history → mod012-card-mod-history}/all/history/actions.rb +8 -4
- data/tmpsets/set/{mod013-card-mod-history → mod012-card-mod-history}/all/history/acts.rb +0 -0
- data/tmpsets/set/{mod013-card-mod-history → mod012-card-mod-history}/all/history/events.rb +3 -3
- data/tmpsets/set/{mod013-card-mod-history → mod012-card-mod-history}/all/history/last.rb +0 -0
- data/tmpsets/set/{mod013-card-mod-history → mod012-card-mod-history}/all/history/revision.rb +0 -0
- data/tmpsets/set/{mod013-card-mod-history → mod012-card-mod-history}/all/history/selected.rb +3 -3
- data/tmpsets/set/{mod013-card-mod-history → mod012-card-mod-history}/all/history/views.rb +31 -0
- data/tmpsets/set/{mod013-card-mod-history → mod012-card-mod-history}/all/history_bridge.rb +31 -17
- data/tmpsets/set/{mod014-card-mod-carrierwave → mod013-card-mod-carrierwave}/abstract/attachment.rb +36 -13
- data/tmpsets/set/{mod014-card-mod-carrierwave → mod013-card-mod-carrierwave}/abstract/attachment/cloud.rb +5 -1
- data/tmpsets/set/{mod014-card-mod-carrierwave → mod013-card-mod-carrierwave}/abstract/attachment/coded.rb +7 -2
- data/tmpsets/set/{mod014-card-mod-carrierwave → mod013-card-mod-carrierwave}/abstract/attachment/local.rb +4 -1
- data/tmpsets/set/{mod014-card-mod-carrierwave → mod013-card-mod-carrierwave}/abstract/attachment/paths.rb +1 -0
- data/tmpsets/set/{mod014-card-mod-carrierwave → mod013-card-mod-carrierwave}/abstract/attachment/storage_type.rb +33 -32
- data/tmpsets/set/{mod014-card-mod-carrierwave → mod013-card-mod-carrierwave}/abstract/attachment/upload_cache.rb +4 -0
- data/tmpsets/set/{mod014-card-mod-carrierwave → mod013-card-mod-carrierwave}/abstract/attachment/web.rb +0 -0
- data/tmpsets/set/{mod014-card-mod-carrierwave → mod013-card-mod-carrierwave}/all/file_utils.rb +0 -0
- data/tmpsets/set/{mod014-card-mod-carrierwave → mod013-card-mod-carrierwave}/self/admin.rb +0 -0
- data/tmpsets/set/{mod014-card-mod-carrierwave → mod013-card-mod-carrierwave}/self/favicon.rb +1 -0
- data/tmpsets/set/{mod014-card-mod-carrierwave → mod013-card-mod-carrierwave}/self/new_file.rb +0 -0
- data/tmpsets/set/{mod014-card-mod-carrierwave → mod013-card-mod-carrierwave}/self/new_image.rb +0 -0
- data/tmpsets/set/{mod014-card-mod-carrierwave → mod013-card-mod-carrierwave}/type/file.rb +27 -10
- data/tmpsets/set/{mod014-card-mod-carrierwave → mod013-card-mod-carrierwave}/type/image.rb +7 -4
- data/tmpsets/set/{mod014-card-mod-carrierwave → mod013-card-mod-carrierwave}/type/image/html_views.rb +13 -3
- data/tmpsets/set/{mod015-card-mod-virtual → mod014-card-mod-virtual}/abstract/virtual_cache.rb +0 -0
- data/tmpsets/set/{mod016-card-mod-machines → mod015-card-mod-machines}/abstract/machine.rb +2 -2
- data/tmpsets/set/{mod016-card-mod-machines → mod015-card-mod-machines}/abstract/machine/output_cache.rb +0 -0
- data/tmpsets/set/{mod016-card-mod-machines → mod015-card-mod-machines}/abstract/machine/output_update.rb +7 -0
- data/tmpsets/set/{mod016-card-mod-machines → mod015-card-mod-machines}/abstract/machine_input.rb +1 -0
- data/tmpsets/set/{mod016-card-mod-machines → mod015-card-mod-machines}/all/reset_machines.rb +0 -0
- data/tmpsets/set/{mod016-card-mod-machines → mod015-card-mod-machines}/right/machine_cache.rb +0 -0
- data/tmpsets/set/{mod016-card-mod-machines → mod015-card-mod-machines}/right/machine_input.rb +0 -0
- data/tmpsets/set/{mod016-card-mod-machines → mod015-card-mod-machines}/right/machine_output.rb +0 -0
- data/tmpsets/set/{mod017-card-mod-script → mod016-card-mod-script}/abstract/script.rb +1 -1
- data/tmpsets/set/{mod017-card-mod-script → mod016-card-mod-script}/right/script.rb +0 -0
- data/tmpsets/set/{mod017-card-mod-script → mod016-card-mod-script}/self/01_script_libraries.rb +0 -0
- data/tmpsets/set/{mod017-card-mod-script → mod016-card-mod-script}/self/script.rb +0 -0
- data/tmpsets/set/{mod017-card-mod-script → mod016-card-mod-script}/self/script_decko.rb +0 -0
- data/tmpsets/set/{mod017-card-mod-script → mod016-card-mod-script}/self/script_editors.rb +0 -0
- data/tmpsets/set/{mod017-card-mod-script → mod016-card-mod-script}/self/script_html5shiv_printshiv.rb +0 -0
- data/tmpsets/set/{mod017-card-mod-script → mod016-card-mod-script}/self/script_jquery.rb +0 -0
- data/tmpsets/set/{mod017-card-mod-script → mod016-card-mod-script}/self/script_jquery_helper.rb +0 -0
- data/tmpsets/set/{mod017-card-mod-script → mod016-card-mod-script}/self/script_mods.rb +0 -0
- data/tmpsets/set/{mod017-card-mod-script → mod016-card-mod-script}/self/script_pointer_config.rb +0 -0
- data/tmpsets/set/{mod017-card-mod-script → mod016-card-mod-script}/type/coffee_script.rb +1 -1
- data/tmpsets/set/{mod017-card-mod-script → mod016-card-mod-script}/type/java_script.rb +0 -0
- data/tmpsets/set/{mod018-card-mod-ace_editor → mod017-card-mod-ace_editor}/all/ace_editor.rb +0 -1
- data/tmpsets/set/{mod018-card-mod-ace_editor → mod017-card-mod-ace_editor}/self/ace.rb +0 -0
- data/tmpsets/set/{mod018-card-mod-ace_editor → mod017-card-mod-ace_editor}/self/script_ace.rb +0 -0
- data/tmpsets/set/{mod018-card-mod-ace_editor → mod017-card-mod-ace_editor}/self/script_ace_config.rb +0 -0
- data/tmpsets/set/mod018-card-mod-alias/all/alias.rb +30 -0
- data/tmpsets/set/mod018-card-mod-alias/all_plus/alias.rb +31 -0
- data/tmpsets/set/mod018-card-mod-alias/type/alias.rb +42 -0
- data/tmpsets/set/mod019-card-mod-api_key/right/account.rb +18 -0
- data/tmpsets/set/mod019-card-mod-api_key/right/api_key.rb +103 -0
- data/tmpsets/set/{mod019-card-mod-style → mod020-card-mod-style}/abstract/skin_box.rb +2 -0
- data/tmpsets/set/{mod019-card-mod-style → mod020-card-mod-style}/right/style.rb +0 -0
- data/tmpsets/set/{mod019-card-mod-style → mod020-card-mod-style}/self/style.rb +0 -0
- data/tmpsets/set/{mod019-card-mod-style → mod020-card-mod-style}/self/style_bootstrap_compatible.rb +0 -0
- data/tmpsets/set/{mod019-card-mod-style → mod020-card-mod-style}/self/style_cards.rb +0 -0
- data/tmpsets/set/{mod019-card-mod-style → mod020-card-mod-style}/self/style_jquery_ui_smoothness.rb +0 -0
- data/tmpsets/set/{mod019-card-mod-style → mod020-card-mod-style}/self/style_libraries.rb +0 -0
- data/tmpsets/set/{mod019-card-mod-style → mod020-card-mod-style}/self/style_mods.rb +0 -0
- data/tmpsets/set/{mod019-card-mod-style → mod020-card-mod-style}/type/css.rb +5 -4
- data/tmpsets/set/{mod019-card-mod-style → mod020-card-mod-style}/type/scss.rb +1 -1
- data/tmpsets/set/{mod019-card-mod-style → mod020-card-mod-style}/type/skin.rb +0 -0
- data/tmpsets/set/{mod020-card-mod-bar_and_box → mod021-card-mod-bar_and_box}/abstract/media.rb +0 -0
- data/tmpsets/set/{mod020-card-mod-bar_and_box → mod021-card-mod-bar_and_box}/all/bar.rb +1 -1
- data/tmpsets/set/{mod020-card-mod-bar_and_box → mod021-card-mod-bar_and_box}/all/box.rb +0 -0
- data/tmpsets/set/{mod020-card-mod-bar_and_box → mod021-card-mod-bar_and_box}/self/style_media.rb +0 -0
- data/tmpsets/set/{mod020-card-mod-bar_and_box → mod021-card-mod-bar_and_box}/type/image.rb +1 -1
- data/tmpsets/set/{mod021-card-mod-bootstrap → mod022-card-mod-bootstrap}/abstract/bootstrap_code_file.rb +0 -1
- data/tmpsets/set/{mod021-card-mod-bootstrap → mod022-card-mod-bootstrap}/abstract/bootswatch_theme.rb +1 -0
- data/tmpsets/set/{mod021-card-mod-bootstrap → mod022-card-mod-bootstrap}/abstract/bootswatch_theme/html_views.rb +0 -0
- data/tmpsets/set/{mod021-card-mod-bootstrap → mod022-card-mod-bootstrap}/abstract/bs_badge.rb +0 -0
- data/tmpsets/set/{mod021-card-mod-bootstrap → mod022-card-mod-bootstrap}/all/bootstrap/accordion.rb +0 -0
- data/tmpsets/set/{mod021-card-mod-bootstrap → mod022-card-mod-bootstrap}/all/bootstrap/dropdown.rb +13 -15
- data/tmpsets/set/{mod021-card-mod-bootstrap → mod022-card-mod-bootstrap}/all/bootstrap/form.rb +0 -0
- data/tmpsets/set/{mod021-card-mod-bootstrap → mod022-card-mod-bootstrap}/all/bootstrap/helper.rb +23 -12
- data/tmpsets/set/{mod021-card-mod-bootstrap → mod022-card-mod-bootstrap}/all/bootstrap/icon.rb +16 -11
- data/tmpsets/set/{mod021-card-mod-bootstrap → mod022-card-mod-bootstrap}/all/bootstrap/navbar.rb +8 -28
- data/tmpsets/set/{mod021-card-mod-bootstrap → mod022-card-mod-bootstrap}/all/bootstrap/table.rb +9 -7
- data/tmpsets/set/{mod021-card-mod-bootstrap → mod022-card-mod-bootstrap}/all/bootstrap/tabs.rb +0 -0
- data/tmpsets/set/{mod021-card-mod-bootstrap → mod022-card-mod-bootstrap}/all/bootstrap/wrapper.rb +2 -3
- data/tmpsets/set/{mod021-card-mod-bootstrap → mod022-card-mod-bootstrap}/all/rich_bootstrap.rb +0 -0
- data/tmpsets/set/{mod021-card-mod-bootstrap → mod022-card-mod-bootstrap}/self/bootstrap_core.rb +7 -6
- data/tmpsets/set/{mod021-card-mod-bootstrap → mod022-card-mod-bootstrap}/self/bootstrap_functions.rb +0 -0
- data/tmpsets/set/{mod021-card-mod-bootstrap → mod022-card-mod-bootstrap}/self/font_awesome.rb +0 -0
- data/tmpsets/set/{mod021-card-mod-bootstrap → mod022-card-mod-bootstrap}/self/material_icons.rb +0 -0
- data/tmpsets/set/{mod021-card-mod-bootstrap → mod022-card-mod-bootstrap}/self/script_bootstrap.rb +0 -0
- data/tmpsets/set/{mod021-card-mod-bootstrap → mod022-card-mod-bootstrap}/self/script_load_select2.rb +0 -0
- data/tmpsets/set/{mod021-card-mod-bootstrap → mod022-card-mod-bootstrap}/self/script_select2.rb +0 -0
- data/tmpsets/set/{mod021-card-mod-bootstrap → mod022-card-mod-bootstrap}/self/smartmenu_css.rb +0 -0
- data/tmpsets/set/{mod021-card-mod-bootstrap → mod022-card-mod-bootstrap}/self/smartmenu_js.rb +0 -0
- data/tmpsets/set/{mod021-card-mod-bootstrap → mod022-card-mod-bootstrap}/self/style_bootstrap_cards.rb +0 -0
- data/tmpsets/set/{mod021-card-mod-bootstrap → mod022-card-mod-bootstrap}/self/style_bootstrap_colorpicker.rb +0 -0
- data/tmpsets/set/{mod021-card-mod-bootstrap → mod022-card-mod-bootstrap}/self/style_select2.rb +0 -0
- data/tmpsets/set/{mod021-card-mod-bootstrap → mod022-card-mod-bootstrap}/self/style_select2_bootstrap.rb +0 -0
- data/tmpsets/set/{mod021-card-mod-bootstrap → mod022-card-mod-bootstrap}/type/bootswatch_skin.rb +0 -0
- data/tmpsets/set/{mod021-card-mod-bootstrap → mod022-card-mod-bootstrap}/type/customized_bootswatch_skin.rb +11 -7
- data/tmpsets/set/{mod021-card-mod-bootstrap → mod022-card-mod-bootstrap}/type/customized_bootswatch_skin/html_views.rb +0 -0
- data/tmpsets/set/{mod021-card-mod-bootstrap → mod022-card-mod-bootstrap}/type_plus_right/customized_bootswatch_skin/colors.rb +3 -2
- data/tmpsets/set/{mod022-card-mod-comment → mod023-card-mod-comment}/all/comment.rb +4 -1
- data/tmpsets/set/{mod022-card-mod-comment → mod023-card-mod-comment}/right/comment.rb +0 -0
- data/tmpsets/set/{mod022-card-mod-comment → mod023-card-mod-comment}/right/discussion.rb +0 -0
- data/tmpsets/set/{mod023-card-mod-date → mod024-card-mod-date}/all/calendar.rb +0 -0
- data/tmpsets/set/{mod023-card-mod-date → mod024-card-mod-date}/right/when_created.rb +1 -0
- data/tmpsets/set/{mod023-card-mod-date → mod024-card-mod-date}/right/when_last_edited.rb +1 -0
- data/tmpsets/set/{mod023-card-mod-date → mod024-card-mod-date}/self/datepicker.rb +1 -1
- data/tmpsets/set/{mod023-card-mod-date → mod024-card-mod-date}/self/now.rb +0 -1
- data/tmpsets/set/{mod023-card-mod-date → mod024-card-mod-date}/self/script_datepicker.rb +0 -0
- data/tmpsets/set/{mod023-card-mod-date → mod024-card-mod-date}/self/script_datepicker_config.rb +0 -0
- data/tmpsets/set/{mod023-card-mod-date → mod024-card-mod-date}/self/style_datepicker.rb +0 -0
- data/tmpsets/set/{mod023-card-mod-date → mod024-card-mod-date}/type/date.rb +0 -0
- data/tmpsets/set/{mod025-card-mod-follow → mod026-card-mod-follow}/abstract/follow_option.rb +0 -0
- data/tmpsets/set/{mod025-card-mod-follow → mod026-card-mod-follow}/all/follow.rb +0 -0
- data/tmpsets/set/{mod025-card-mod-follow → mod026-card-mod-follow}/all/follow/follow_link.rb +3 -2
- data/tmpsets/set/{mod025-card-mod-follow → mod026-card-mod-follow}/all/follow/follow_link_views.rb +0 -0
- data/tmpsets/set/{mod025-card-mod-follow → mod026-card-mod-follow}/all/follow/followed_by.rb +0 -0
- data/tmpsets/set/{mod025-card-mod-follow → mod026-card-mod-follow}/all/follow/follower_ids.rb +0 -0
- data/tmpsets/set/{mod025-card-mod-follow → mod026-card-mod-follow}/all/follow/start_follow_link.rb +0 -0
- data/tmpsets/set/{mod025-card-mod-follow → mod026-card-mod-follow}/all/follow/stop_follow_link.rb +0 -0
- data/tmpsets/set/{mod025-card-mod-follow → mod026-card-mod-follow}/all/notify.rb +1 -0
- data/tmpsets/set/{mod025-card-mod-follow → mod026-card-mod-follow}/all/notify/base_views.rb +1 -0
- data/tmpsets/set/{mod025-card-mod-follow → mod026-card-mod-follow}/all/notify/html_views.rb +0 -0
- data/tmpsets/set/{mod025-card-mod-follow → mod026-card-mod-follow}/right/account.rb +0 -0
- data/tmpsets/set/{mod025-card-mod-follow → mod026-card-mod-follow}/right/follow.rb +1 -1
- data/tmpsets/set/{mod025-card-mod-follow → mod026-card-mod-follow}/right/follow_fields.rb +0 -0
- data/tmpsets/set/{mod025-card-mod-follow → mod026-card-mod-follow}/right/followers.rb +0 -0
- data/tmpsets/set/{mod025-card-mod-follow → mod026-card-mod-follow}/right/following.rb +0 -0
- data/tmpsets/set/{mod025-card-mod-follow → mod026-card-mod-follow}/self/always.rb +0 -0
- data/tmpsets/set/{mod025-card-mod-follow → mod026-card-mod-follow}/self/created.rb +0 -0
- data/tmpsets/set/{mod025-card-mod-follow → mod026-card-mod-follow}/self/edited.rb +0 -0
- data/tmpsets/set/{mod025-card-mod-follow → mod026-card-mod-follow}/self/follow.rb +0 -0
- data/tmpsets/set/{mod025-card-mod-follow → mod026-card-mod-follow}/self/follow_defaults.rb +5 -4
- data/tmpsets/set/{mod025-card-mod-follow → mod026-card-mod-follow}/self/follow_fields.rb +0 -0
- data/tmpsets/set/{mod025-card-mod-follow → mod026-card-mod-follow}/self/never.rb +0 -0
- data/tmpsets/set/{mod025-card-mod-follow → mod026-card-mod-follow}/type/cardtype.rb +1 -1
- data/tmpsets/set/{mod025-card-mod-follow → mod026-card-mod-follow}/type/notification_template.rb +0 -0
- data/tmpsets/set/{mod025-card-mod-follow → mod026-card-mod-follow}/type/set.rb +0 -0
- data/tmpsets/set/{mod025-card-mod-follow → mod026-card-mod-follow}/type/user.rb +0 -0
- data/tmpsets/set/{mod025-card-mod-follow → mod026-card-mod-follow}/type_plus_right/user/follow.rb +3 -2
- data/tmpsets/set/{mod025-card-mod-follow → mod026-card-mod-follow}/type_plus_right/user/follow/follow_editor_helper.rb +0 -0
- data/tmpsets/set/{mod026-card-mod-google_analytics → mod027-card-mod-google_analytics}/all/google_analytics.rb +0 -0
- data/tmpsets/set/{mod027-card-mod-help → mod028-card-mod-help}/all/guide.rb +0 -0
- data/tmpsets/set/{mod027-card-mod-help → mod028-card-mod-help}/all/help.rb +0 -0
- data/tmpsets/set/{mod027-card-mod-help → mod028-card-mod-help}/right/guide.rb +0 -0
- data/tmpsets/set/{mod027-card-mod-help → mod028-card-mod-help}/right/help.rb +1 -1
- data/tmpsets/set/{mod027-card-mod-help → mod028-card-mod-help}/self/guide.rb +0 -0
- data/tmpsets/set/{mod027-card-mod-help → mod028-card-mod-help}/self/help.rb +0 -0
- data/tmpsets/set/{mod028-card-mod-integrate → mod029-card-mod-integrate}/all/observer.rb +0 -0
- data/tmpsets/set/{mod028-card-mod-integrate → mod029-card-mod-integrate}/self/on_create.rb +0 -0
- data/tmpsets/set/{mod028-card-mod-integrate → mod029-card-mod-integrate}/self/on_delete.rb +0 -0
- data/tmpsets/set/{mod028-card-mod-integrate → mod029-card-mod-integrate}/self/on_update.rb +0 -0
- data/tmpsets/set/{mod028-card-mod-integrate → mod029-card-mod-integrate}/self/thanks.rb +0 -0
- data/tmpsets/set/{mod029-card-mod-session → mod030-card-mod-session}/all/location_history.rb +0 -0
- data/tmpsets/set/{mod029-card-mod-session → mod030-card-mod-session}/type/session.rb +0 -0
- data/tmpsets/set/{mod030-card-mod-layout → mod031-card-mod-layout}/abstract/account_dropdown.rb +2 -4
- data/tmpsets/set/{mod030-card-mod-layout → mod031-card-mod-layout}/abstract/pointer/html_views.rb +0 -0
- data/tmpsets/set/{mod030-card-mod-layout → mod031-card-mod-layout}/all/alert.rb +0 -0
- data/tmpsets/set/{mod030-card-mod-layout → mod031-card-mod-layout}/all/layouts.rb +0 -0
- data/tmpsets/set/{mod030-card-mod-layout → mod031-card-mod-layout}/all/modal.rb +1 -0
- data/tmpsets/set/{mod030-card-mod-layout → mod031-card-mod-layout}/all/navbar_links.rb +0 -0
- data/tmpsets/set/{mod030-card-mod-layout → mod031-card-mod-layout}/all/overlay.rb +7 -10
- data/tmpsets/set/{mod030-card-mod-layout → mod031-card-mod-layout}/all/process_layout.rb +31 -29
- data/tmpsets/set/{mod030-card-mod-layout → mod031-card-mod-layout}/all/tabs.rb +1 -0
- data/tmpsets/set/{mod030-card-mod-layout → mod031-card-mod-layout}/right/enabled_roles.rb +0 -0
- data/tmpsets/set/{mod030-card-mod-layout → mod031-card-mod-layout}/right/head.rb +0 -0
- data/tmpsets/set/{mod030-card-mod-layout → mod031-card-mod-layout}/self/account_links.rb +6 -7
- data/tmpsets/set/{mod030-card-mod-layout → mod031-card-mod-layout}/self/alerts.rb +0 -0
- data/tmpsets/set/{mod030-card-mod-layout → mod031-card-mod-layout}/self/dropdown_divider.rb +0 -0
- data/tmpsets/set/{mod030-card-mod-layout → mod031-card-mod-layout}/self/foot.rb +0 -1
- data/tmpsets/set/{mod030-card-mod-layout → mod031-card-mod-layout}/self/head.rb +1 -1
- data/tmpsets/set/{mod030-card-mod-layout → mod031-card-mod-layout}/self/layout.rb +0 -0
- data/tmpsets/set/{mod030-card-mod-layout → mod031-card-mod-layout}/self/navbox.rb +0 -0
- data/tmpsets/set/{mod030-card-mod-layout → mod031-card-mod-layout}/self/sidebar.rb +0 -0
- data/tmpsets/set/{mod030-card-mod-layout → mod031-card-mod-layout}/type/html.rb +0 -0
- data/tmpsets/set/{mod030-card-mod-layout → mod031-card-mod-layout}/type/layout_type.rb +0 -0
- data/tmpsets/set/{mod031-card-mod-legacy → mod032-card-mod-legacy}/abstract/table_of_contents.rb +9 -6
- data/tmpsets/set/{mod031-card-mod-legacy → mod032-card-mod-legacy}/self/csv_structure.rb +0 -0
- data/tmpsets/set/{mod031-card-mod-legacy → mod032-card-mod-legacy}/self/default_html_view.rb +0 -0
- data/tmpsets/set/{mod031-card-mod-legacy → mod032-card-mod-legacy}/self/table_of_contents.rb +0 -0
- data/tmpsets/set/{mod031-card-mod-legacy → mod032-card-mod-legacy}/type/basic.rb +0 -0
- data/tmpsets/set/{mod032-card-mod-markdown → mod033-card-mod-markdown}/type/markdown.rb +0 -0
- data/tmpsets/set/{mod033-card-mod-prosemirror_editor → mod034-card-mod-prosemirror_editor}/all/prosemirror_editor.rb +0 -1
- data/tmpsets/set/{mod033-card-mod-prosemirror_editor → mod034-card-mod-prosemirror_editor}/self/script_prosemirror.rb +0 -0
- data/tmpsets/set/{mod033-card-mod-prosemirror_editor → mod034-card-mod-prosemirror_editor}/self/script_prosemirror_config.rb +0 -0
- data/tmpsets/set/{mod033-card-mod-prosemirror_editor → mod034-card-mod-prosemirror_editor}/self/style_prosemirror.rb +0 -0
- data/tmpsets/set/{mod034-card-mod-recaptcha → mod035-card-mod-recaptcha}/all/recaptcha.rb +6 -6
- data/tmpsets/set/{mod034-card-mod-recaptcha → mod035-card-mod-recaptcha}/self/admin_info.rb +6 -11
- data/tmpsets/set/{mod011-card-mod-account → mod035-card-mod-recaptcha}/self/captcha.rb +2 -2
- data/tmpsets/set/{mod034-card-mod-recaptcha → mod035-card-mod-recaptcha}/self/recaptcha_proxy.rb +0 -0
- data/tmpsets/set/{mod034-card-mod-recaptcha → mod035-card-mod-recaptcha}/self/recaptcha_secret_key.rb +0 -0
- data/tmpsets/set/{mod034-card-mod-recaptcha → mod035-card-mod-recaptcha}/self/recaptcha_settings.rb +9 -22
- data/tmpsets/set/{mod034-card-mod-recaptcha → mod035-card-mod-recaptcha}/self/recaptcha_site_key.rb +0 -0
- data/tmpsets/set/{mod035-card-mod-search → mod036-card-mod-search}/abstract/00_filter_helper.rb +0 -0
- data/tmpsets/set/{mod035-card-mod-search → mod036-card-mod-search}/abstract/02_search_params.rb +1 -3
- data/tmpsets/set/{mod035-card-mod-search → mod036-card-mod-search}/abstract/03_filter.rb +0 -0
- data/tmpsets/set/{mod035-card-mod-search → mod036-card-mod-search}/abstract/03_filter/filter_form.rb +0 -0
- data/tmpsets/set/{mod035-card-mod-search → mod036-card-mod-search}/abstract/03_filter/form_helper.rb +1 -1
- data/tmpsets/set/{mod035-card-mod-search → mod036-card-mod-search}/abstract/03_filter/query_construction.rb +0 -0
- data/tmpsets/set/{mod035-card-mod-search → mod036-card-mod-search}/abstract/04_right_filter_form.rb +0 -0
- data/tmpsets/set/{mod035-card-mod-search → mod036-card-mod-search}/abstract/05_search.rb +4 -0
- data/tmpsets/set/{mod035-card-mod-search → mod036-card-mod-search}/abstract/05_search/views.rb +3 -5
- data/tmpsets/set/{mod035-card-mod-search → mod036-card-mod-search}/abstract/06_cql_search.rb +2 -0
- data/tmpsets/set/{mod035-card-mod-search → mod036-card-mod-search}/abstract/filterable.rb +0 -0
- data/tmpsets/set/{mod035-card-mod-search → mod036-card-mod-search}/abstract/filterable_bar.rb +0 -0
- data/tmpsets/set/{mod035-card-mod-search → mod036-card-mod-search}/right/children.rb +0 -0
- data/tmpsets/set/{mod035-card-mod-search → mod036-card-mod-search}/right/created.rb +0 -0
- data/tmpsets/set/{mod035-card-mod-search → mod036-card-mod-search}/right/edited.rb +0 -0
- data/tmpsets/set/{mod035-card-mod-search → mod036-card-mod-search}/right/editors.rb +0 -0
- data/tmpsets/set/{mod035-card-mod-search → mod036-card-mod-search}/right/follow.rb +0 -0
- data/tmpsets/set/{mod035-card-mod-search → mod036-card-mod-search}/right/linked_to_by.rb +0 -0
- data/tmpsets/set/{mod035-card-mod-search → mod036-card-mod-search}/right/links_to.rb +0 -0
- data/tmpsets/set/{mod035-card-mod-search → mod036-card-mod-search}/right/mates.rb +0 -0
- data/tmpsets/set/{mod035-card-mod-search → mod036-card-mod-search}/right/nested_by.rb +0 -0
- data/tmpsets/set/{mod035-card-mod-search → mod036-card-mod-search}/right/nests.rb +0 -0
- data/tmpsets/set/{mod035-card-mod-search → mod036-card-mod-search}/right/referred_to_by.rb +0 -0
- data/tmpsets/set/{mod035-card-mod-search → mod036-card-mod-search}/right/refers_to.rb +0 -0
- data/tmpsets/set/{mod035-card-mod-search → mod036-card-mod-search}/self/recent.rb +0 -0
- data/tmpsets/set/{mod035-card-mod-search → mod036-card-mod-search}/self/search.rb +3 -1
- data/tmpsets/set/{mod035-card-mod-search → mod036-card-mod-search}/type/cardtype.rb +0 -0
- data/tmpsets/set/{mod035-card-mod-search → mod036-card-mod-search}/type/search_type.rb +1 -0
- data/tmpsets/set/mod037-card-mod-rules/all/related_sets.rb +34 -0
- data/tmpsets/set/{mod036-card-mod-rules → mod037-card-mod-rules}/right/self.rb +0 -0
- data/tmpsets/set/{mod036-card-mod-rules → mod037-card-mod-rules}/right/type_plus_right.rb +0 -0
- data/tmpsets/set/{mod036-card-mod-rules → mod037-card-mod-rules}/rstar/rule_user.rb +2 -3
- data/tmpsets/set/{mod036-card-mod-rules → mod037-card-mod-rules}/rule/bar_view.rb +0 -0
- data/tmpsets/set/{mod036-card-mod-rules → mod037-card-mod-rules}/rule/bridge_rules_editor.rb +0 -0
- data/tmpsets/set/{mod036-card-mod-rules → mod037-card-mod-rules}/rule/editor.rb +1 -1
- data/tmpsets/set/{mod036-card-mod-rules → mod037-card-mod-rules}/rule/html_views.rb +0 -0
- data/tmpsets/set/{mod036-card-mod-rules → mod037-card-mod-rules}/rule/quick_editor.rb +0 -0
- data/tmpsets/set/{mod036-card-mod-rules → mod037-card-mod-rules}/rule/rule_form.rb +2 -3
- data/tmpsets/set/{mod036-card-mod-rules → mod037-card-mod-rules}/rule/rule_form/buttons.rb +1 -2
- data/tmpsets/set/{mod036-card-mod-rules → mod037-card-mod-rules}/rule/rule_form/form_elements.rb +2 -2
- data/tmpsets/set/{mod036-card-mod-rules → mod037-card-mod-rules}/rule/rule_form/rule_set_radio.rb +1 -0
- data/tmpsets/set/{mod036-card-mod-rules → mod037-card-mod-rules}/rule/rule_form/set_selection.rb +0 -0
- data/tmpsets/set/{mod036-card-mod-rules → mod037-card-mod-rules}/rule/rules.rb +5 -5
- data/tmpsets/set/{mod036-card-mod-rules → mod037-card-mod-rules}/self/cardtype.rb +0 -0
- data/tmpsets/set/{mod036-card-mod-rules → mod037-card-mod-rules}/self/recent_settings.rb +0 -0
- data/tmpsets/set/{mod036-card-mod-rules → mod037-card-mod-rules}/self/script_rules.rb +0 -0
- data/tmpsets/set/mod037-card-mod-rules/type/cardtype.rb +14 -0
- data/tmpsets/set/{mod036-card-mod-rules → mod037-card-mod-rules}/type/set.rb +1 -1
- data/tmpsets/set/{mod036-card-mod-rules → mod037-card-mod-rules}/type/set/html_views.rb +0 -0
- data/tmpsets/set/{mod036-card-mod-rules → mod037-card-mod-rules}/type/set/html_views/rule_lists.rb +0 -0
- data/tmpsets/set/{mod036-card-mod-rules → mod037-card-mod-rules}/type/set/html_views/template.rb +0 -0
- data/tmpsets/set/{mod036-card-mod-rules → mod037-card-mod-rules}/type/set/rules_filter.rb +0 -0
- data/tmpsets/set/{mod036-card-mod-rules → mod037-card-mod-rules}/type/set/setting_lists.rb +1 -1
- data/tmpsets/set/{mod036-card-mod-rules → mod037-card-mod-rules}/type/setting.rb +5 -7
- data/tmpsets/set/{mod037-card-mod-tinymce_editor → mod038-card-mod-tinymce_editor}/all/reference_editor.rb +18 -6
- data/tmpsets/set/{mod037-card-mod-tinymce_editor → mod038-card-mod-tinymce_editor}/all/reference_editor/link_editor.rb +0 -0
- data/tmpsets/set/{mod037-card-mod-tinymce_editor → mod038-card-mod-tinymce_editor}/all/reference_editor/link_editor/link_parser.rb +0 -0
- data/tmpsets/set/{mod037-card-mod-tinymce_editor → mod038-card-mod-tinymce_editor}/all/reference_editor/nest_editor.rb +1 -2
- data/tmpsets/set/{mod037-card-mod-tinymce_editor → mod038-card-mod-tinymce_editor}/all/reference_editor/nest_image.rb +0 -2
- data/tmpsets/set/{mod037-card-mod-tinymce_editor → mod038-card-mod-tinymce_editor}/all/tinymce_editor.rb +0 -1
- data/tmpsets/set/{mod037-card-mod-tinymce_editor → mod038-card-mod-tinymce_editor}/self/script_tinymce.rb +0 -0
- data/tmpsets/set/{mod037-card-mod-tinymce_editor → mod038-card-mod-tinymce_editor}/self/script_tinymce_config.rb +0 -0
- data/tmpsets/set/{mod037-card-mod-tinymce_editor → mod038-card-mod-tinymce_editor}/self/tiny_mce.rb +2 -2
- data/tmpsets/set/{mod039-card-mod-monkey → mod040-card-mod-monkey}/all/event_viz.rb +3 -3
- data/tmpsets/set/{mod039-card-mod-monkey → mod040-card-mod-monkey}/all/view_viz.rb +2 -0
- data/tmpsets/set/{mod039-card-mod-monkey → mod040-card-mod-monkey}/right/debug.rb +2 -3
- data/tmpsets/set_pattern/100-all.rb +0 -1
- data/tmpsets/set_pattern/101-all_plus.rb +0 -1
- data/tmpsets/set_pattern/102-type.rb +0 -1
- data/tmpsets/set_pattern/103-star.rb +0 -1
- data/tmpsets/set_pattern/104-rstar.rb +0 -1
- data/tmpsets/set_pattern/105-rule.rb +1 -2
- data/tmpsets/set_pattern/106-right.rb +0 -1
- data/tmpsets/set_pattern/107-type_plus_right.rb +0 -1
- data/tmpsets/set_pattern/108-self.rb +0 -1
- metadata +446 -448
- data/lib/card/mod_inflector.rb +0 -16
- data/lib/card/name/all/class_methods.rb +0 -28
- data/mod/core/set/all/actify.rb +0 -68
- data/mod/core/set/all/cache.rb +0 -109
- data/mod/core/set/all/contextual_content.rb +0 -28
- data/mod/core/set/all/event_conditions.rb +0 -172
- data/mod/core/set/all/fetch.rb +0 -122
- data/mod/core/set/all/fetch_helper.rb +0 -35
- data/mod/core/set/all/i18n.rb +0 -11
- data/mod/core/set/all/pattern.rb +0 -54
- data/mod/core/set/all/references.rb +0 -191
- data/mod/core/set/all/rename.rb +0 -33
- data/mod/core/set/all/rules.rb +0 -81
- data/mod/core/spec/set/all/actify_spec.rb +0 -58
- data/mod/core/spec/set/all/content_spec.rb +0 -15
- data/mod/core/spec/set/all/event_conditions_spec.rb +0 -217
- data/mod/core/spec/set/all/fetch_helper_spec.rb +0 -65
- data/mod/core/spec/set/all/fetch_spec.rb +0 -338
- data/mod/core/spec/set/all/i18n_spec.rb +0 -17
- data/mod/core/spec/set/all/pattern_spec.rb +0 -101
- data/mod/core/spec/set/all/permissions/reader_rules_spec.rb +0 -166
- data/mod/core/spec/set/all/references_spec.rb +0 -62
- data/mod/core/spec/set/all/rename_spec.rb +0 -189
- data/mod/core/spec/set/all/rules_spec.rb +0 -100
- data/mod/core/spec/set/all/subcards_spec.rb +0 -102
- data/tmpsets/set/mod002-core/all/actify.rb +0 -77
- data/tmpsets/set/mod002-core/all/cache.rb +0 -118
- data/tmpsets/set/mod002-core/all/event_conditions.rb +0 -181
- data/tmpsets/set/mod002-core/all/fetch.rb +0 -131
- data/tmpsets/set/mod002-core/all/fetch_helper.rb +0 -44
- data/tmpsets/set/mod002-core/all/i18n.rb +0 -20
- data/tmpsets/set/mod002-core/all/name.rb +0 -238
- data/tmpsets/set/mod002-core/all/pattern.rb +0 -63
- data/tmpsets/set/mod002-core/all/references.rb +0 -200
- data/tmpsets/set/mod002-core/all/rename.rb +0 -42
- data/tmpsets/set/mod002-core/all/rules.rb +0 -90
- data/tmpsets/set/mod003-settings/right/autoname.rb +0 -12
- data/tmpsets/set/mod004-standard/all/rich_html/html_views/info.rb +0 -93
- data/tmpsets/set/mod004-standard/type/cardtype.rb +0 -128
- data/tmpsets/set/mod011-card-mod-account/right/api_key.rb +0 -57
@@ -1,15 +0,0 @@
|
|
1
|
-
# -*- encoding : utf-8 -*-
|
2
|
-
|
3
|
-
describe Card::Set::All::Content do
|
4
|
-
describe "save_content_draft" do
|
5
|
-
it "stores a draft revision" do
|
6
|
-
@card = Card.create! name: "mango", content: "foo"
|
7
|
-
@card.save_content_draft("bar")
|
8
|
-
expect(@card.drafts.length).to eq 1
|
9
|
-
@card.save_content_draft("booboo")
|
10
|
-
@card.reload
|
11
|
-
expect(@card.drafts.length).to eq 1
|
12
|
-
expect(@card.drafts[0].value(:db_content)).to eq "booboo"
|
13
|
-
end
|
14
|
-
end
|
15
|
-
end
|
@@ -1,217 +0,0 @@
|
|
1
|
-
# -*- encoding : utf-8 -*-
|
2
|
-
|
3
|
-
RSpec.describe Card::Set::All::EventConditions do
|
4
|
-
let(:create_card) {Card.create!(name: "main card")}
|
5
|
-
let(:create_card_with_subcards) do
|
6
|
-
Card.create name: "main card",
|
7
|
-
subcards: {
|
8
|
-
"11" => { subcards: { "111" => "A" } },
|
9
|
-
"12" => { subcards: { "121" => "A" } }
|
10
|
-
}
|
11
|
-
end
|
12
|
-
|
13
|
-
context "restricted to changed content:" do
|
14
|
-
STAGES = [:validate, :store, :finalize, :integrate]
|
15
|
-
|
16
|
-
def add_to_log entry
|
17
|
-
@log << entry
|
18
|
-
end
|
19
|
-
|
20
|
-
def change_content
|
21
|
-
Card["A"].update! content: "changed content"
|
22
|
-
end
|
23
|
-
|
24
|
-
before do
|
25
|
-
@log = []
|
26
|
-
end
|
27
|
-
|
28
|
-
it "is executed when content changed" do
|
29
|
-
with_test_events do
|
30
|
-
STAGES.each do |stage|
|
31
|
-
test_event stage, on: :update, changed: :content, for: "A" do
|
32
|
-
# can't access instance variables here but methods are fine
|
33
|
-
add_to_log stage
|
34
|
-
end
|
35
|
-
end
|
36
|
-
change_content
|
37
|
-
expect(@log).to contain_exactly(*STAGES)
|
38
|
-
end
|
39
|
-
end
|
40
|
-
|
41
|
-
specify "content change is accessible in all stages" do
|
42
|
-
with_test_events do
|
43
|
-
STAGES.each do |stage|
|
44
|
-
test_event stage, on: :update, changed: :content, for: "A" do
|
45
|
-
add_to_log db_content_before_act
|
46
|
-
end
|
47
|
-
end
|
48
|
-
content_before_change = [Card["A"].db_content] * STAGES.size
|
49
|
-
change_content
|
50
|
-
expect(@log).to contain_exactly(*content_before_change)
|
51
|
-
end
|
52
|
-
end
|
53
|
-
|
54
|
-
context "when changing type" do
|
55
|
-
def update_type
|
56
|
-
Card::Auth.as_bot do
|
57
|
-
Card["Sample Pointer"].update! type: "Search"
|
58
|
-
end
|
59
|
-
end
|
60
|
-
|
61
|
-
it "does NOT run update events from sets that no longer apply after change" do
|
62
|
-
with_test_events do
|
63
|
-
test_event :validate, on: :update, set: Card::Set::Type::Pointer do
|
64
|
-
add_to_log "NO to run"
|
65
|
-
end
|
66
|
-
update_type
|
67
|
-
expect(@log).to be_empty
|
68
|
-
end
|
69
|
-
end
|
70
|
-
|
71
|
-
it "does run update events from old sets when `changing` value present" do
|
72
|
-
with_test_events do
|
73
|
-
test_event :validate,
|
74
|
-
on: :update, set: Card::Set::Type::Pointer, changing: :type do
|
75
|
-
add_to_log "YES to run"
|
76
|
-
end
|
77
|
-
update_type
|
78
|
-
expect(@log).to contain_exactly("YES to run")
|
79
|
-
end
|
80
|
-
end
|
81
|
-
|
82
|
-
it "does run update events from sets that apply after change" do
|
83
|
-
with_test_events do
|
84
|
-
test_event :validate, on: :update, set: Card::Set::Type::SearchType do
|
85
|
-
add_to_log "YES to run"
|
86
|
-
end
|
87
|
-
update_type
|
88
|
-
expect(@log).to contain_exactly("YES to run")
|
89
|
-
end
|
90
|
-
end
|
91
|
-
|
92
|
-
# following does not yet work, because old card has both old sets and new sets
|
93
|
-
# when conditions are tested.
|
94
|
-
xit "does NOT run update events from new sets when `changing` value present" do
|
95
|
-
with_test_events do
|
96
|
-
test_event :validate,
|
97
|
-
on: :update, set: Card::Set::Type::SearchType, changing: :type do
|
98
|
-
add_to_log "NO to run"
|
99
|
-
end
|
100
|
-
update_type
|
101
|
-
expect(@log).to be_empty
|
102
|
-
end
|
103
|
-
end
|
104
|
-
end
|
105
|
-
|
106
|
-
context "when changing name" do
|
107
|
-
def update_name
|
108
|
-
Card::Auth.as_bot do
|
109
|
-
Card["Cardtype B+*type+*create"].update! name: "B+*update"
|
110
|
-
end
|
111
|
-
end
|
112
|
-
|
113
|
-
it "does NOT run update events from sets that no longer apply after change" do
|
114
|
-
with_test_events do
|
115
|
-
test_event :validate, on: :update, set: Card::Set::Right::Create do
|
116
|
-
add_to_log "NO to run"
|
117
|
-
end
|
118
|
-
update_name
|
119
|
-
expect(@log).to be_empty
|
120
|
-
end
|
121
|
-
end
|
122
|
-
|
123
|
-
it "does run update events from old sets when `changing` value present" do
|
124
|
-
with_test_events do
|
125
|
-
test_event :validate,
|
126
|
-
on: :update, set: Card::Set::Right::Create, changing: :name do
|
127
|
-
add_to_log "YES to run"
|
128
|
-
end
|
129
|
-
update_name
|
130
|
-
expect(@log).to contain_exactly("YES to run")
|
131
|
-
end
|
132
|
-
end
|
133
|
-
|
134
|
-
it "does run update events from sets that apply after change" do
|
135
|
-
with_test_events do
|
136
|
-
test_event :validate, on: :update, set: Card::Set::Right::Update do
|
137
|
-
add_to_log "YES to run"
|
138
|
-
end
|
139
|
-
update_name
|
140
|
-
expect(@log).to contain_exactly("YES to run")
|
141
|
-
end
|
142
|
-
end
|
143
|
-
end
|
144
|
-
|
145
|
-
describe "trigger option" do
|
146
|
-
specify "trigger for whole act" do
|
147
|
-
with_test_events do
|
148
|
-
test_event :validate, on: :update, trigger: :required, for: "A" do
|
149
|
-
add_to_log "triggered"
|
150
|
-
end
|
151
|
-
Card["A"].update! content: "changed content"
|
152
|
-
|
153
|
-
aggregate_failures do
|
154
|
-
expect(@log).to be_empty
|
155
|
-
Card["A"].update! content: "changed content", trigger: :test_event_0
|
156
|
-
expect(@log).to contain_exactly "triggered"
|
157
|
-
end
|
158
|
-
end
|
159
|
-
end
|
160
|
-
end
|
161
|
-
|
162
|
-
describe "skip option" do
|
163
|
-
def expect_skipping changes, log1, log2,
|
164
|
-
for_name: nil, skip_key: :skip, allowed: :allowed, force: false
|
165
|
-
with_test_events do
|
166
|
-
add_logging_test_event allowed, for_name
|
167
|
-
update_with_skip force, changes, skip_key
|
168
|
-
|
169
|
-
aggregate_failures do
|
170
|
-
expect(@log).to eq(log1) # logging with skip
|
171
|
-
Card["A"].update! changes # update without skip
|
172
|
-
expect(@log).to contain_exactly(*log2) # logging without skip
|
173
|
-
end
|
174
|
-
end
|
175
|
-
end
|
176
|
-
|
177
|
-
def add_logging_test_event allowed, for_name
|
178
|
-
event_args = { on: :update, skip: allowed }
|
179
|
-
event_args[:for] = for_name if for_name
|
180
|
-
test_event(:validate, event_args) do
|
181
|
-
add_to_log "#{name} executed"
|
182
|
-
end
|
183
|
-
end
|
184
|
-
|
185
|
-
def update_with_skip force, changes, skip_key
|
186
|
-
skip_card = Card["A"]
|
187
|
-
if force
|
188
|
-
skip_card.skip_event! :test_event_0
|
189
|
-
skip_card.update! changes
|
190
|
-
else
|
191
|
-
skip_card.update! changes.merge(skip_key => :test_event_0)
|
192
|
-
end
|
193
|
-
end
|
194
|
-
|
195
|
-
specify "skip condition" do
|
196
|
-
expect_skipping({ content: "changed" }, [], "A executed", for_name: "A")
|
197
|
-
end
|
198
|
-
|
199
|
-
specify "skip condition in subcard" do
|
200
|
-
expect_skipping({ content: "changed", subcards: { "+B" => "changed +B" } },
|
201
|
-
[], "A+B executed", for_name: "A+B")
|
202
|
-
end
|
203
|
-
|
204
|
-
specify "skip_in_action condition" do
|
205
|
-
expect_skipping({ content: "changed", subcards: { "+B" => "changed +B" } },
|
206
|
-
["A+B executed"],
|
207
|
-
["A executed", "A+B executed", "A+B executed"],
|
208
|
-
skip_key: :skip_in_action)
|
209
|
-
end
|
210
|
-
|
211
|
-
specify "force skip" do
|
212
|
-
expect_skipping({ content: "changed" }, [], "A executed",
|
213
|
-
force: true, for_name: "A")
|
214
|
-
end
|
215
|
-
end
|
216
|
-
end
|
217
|
-
end
|
@@ -1,65 +0,0 @@
|
|
1
|
-
# -*- encoding : utf-8 -*-
|
2
|
-
|
3
|
-
RSpec.describe Card::Set::All::FetchHelper do
|
4
|
-
let(:retrieve) { test_retrieve_existing }
|
5
|
-
let(:retrieve_from_trash) { test_retrieve_existing look_in_trash: true }
|
6
|
-
|
7
|
-
def fetch_object opts={}
|
8
|
-
if @fetch_object
|
9
|
-
@fetch_object.opts.merge! opts
|
10
|
-
@fetch_object
|
11
|
-
else
|
12
|
-
@fetch_object = Card::Fetch.new("A".to_name, opts)
|
13
|
-
end
|
14
|
-
end
|
15
|
-
|
16
|
-
def test_retrieve_existing opts={}
|
17
|
-
fetch_object(opts)&.retrieve_existing
|
18
|
-
end
|
19
|
-
|
20
|
-
describe "#controller fetch" do
|
21
|
-
it "removes underscores from new card names" do
|
22
|
-
expect(Card.controller_fetch(mark: "no_un_der_score").name).to eq("no un der score")
|
23
|
-
end
|
24
|
-
end
|
25
|
-
|
26
|
-
describe "retrieve_existing" do
|
27
|
-
it "looks for non-cached card in database" do
|
28
|
-
# expect_db_retrieval_with(:key, "a", nil) { retrieve }
|
29
|
-
expect_db_retrieval { retrieve }
|
30
|
-
end
|
31
|
-
|
32
|
-
it "doesn't look in db for cached cards(real)" do
|
33
|
-
Card.cache.write "a", Card["B"]
|
34
|
-
expect_no_db_retrieval { retrieve }
|
35
|
-
end
|
36
|
-
|
37
|
-
it "doesn't look in db for cached cards (new)" do
|
38
|
-
Card.cache.write "a", Card.new
|
39
|
-
expect_no_db_retrieval { retrieve }
|
40
|
-
end
|
41
|
-
|
42
|
-
it "doesn't look in db for cached cards (real) if 'look_in_trash' option used" do
|
43
|
-
Card.cache.write "a", Card["B"]
|
44
|
-
expect_no_db_retrieval { retrieve_from_trash }
|
45
|
-
end
|
46
|
-
|
47
|
-
it "looks in db for cached cards (new) if 'look_in_trash' option used" do
|
48
|
-
Card.cache.write "a", Card.new
|
49
|
-
# expect_db_retrieval_with(:key, "a", true) { retrieve_from_trash }
|
50
|
-
expect_db_retrieval { retrieve_from_trash }
|
51
|
-
end
|
52
|
-
|
53
|
-
def expect_no_db_retrieval
|
54
|
-
allow(fetch_object).to receive(:retrieve_from_db)
|
55
|
-
yield
|
56
|
-
expect(fetch_object).not_to have_received(:retrieve_from_db)
|
57
|
-
end
|
58
|
-
|
59
|
-
def expect_db_retrieval
|
60
|
-
allow(fetch_object).to receive(:retrieve_from_db)
|
61
|
-
yield
|
62
|
-
expect(fetch_object).to have_received(:retrieve_from_db) # .with(*args)
|
63
|
-
end
|
64
|
-
end
|
65
|
-
end
|
@@ -1,338 +0,0 @@
|
|
1
|
-
# -*- encoding : utf-8 -*-
|
2
|
-
|
3
|
-
RSpec.describe Card::Set::All::Fetch do
|
4
|
-
describe "#fetch" do
|
5
|
-
it "returns and caches existing cards" do
|
6
|
-
card_double = class_double("Card")
|
7
|
-
expect(Card.fetch("A")).to be_instance_of(Card)
|
8
|
-
expect(Card.cache.read("a")).to be_instance_of(Card)
|
9
|
-
expect(card_double).not_to receive(:find_by_key)
|
10
|
-
expect(Card.fetch("A")).to be_instance_of(Card)
|
11
|
-
end
|
12
|
-
|
13
|
-
it "returns nil and caches missing cards" do
|
14
|
-
expect(Card.fetch("Zork")).to be_nil
|
15
|
-
expect(Card.cache.read("zork").new_card?).to be_truthy
|
16
|
-
expect(Card.fetch("Zork")).to be_nil
|
17
|
-
end
|
18
|
-
|
19
|
-
it "returns nil and caches trash cards" do
|
20
|
-
Card::Auth.as_bot do
|
21
|
-
card_double = class_double("Card")
|
22
|
-
Card.fetch("A").delete!
|
23
|
-
expect(Card.fetch("A")).to be_nil
|
24
|
-
expect(card_double).not_to receive(:find_by_key_and_trash)
|
25
|
-
expect(Card.fetch("A")).to be_nil
|
26
|
-
end
|
27
|
-
end
|
28
|
-
|
29
|
-
it "returns and caches builtin cards" do
|
30
|
-
expect(Card.fetch("*head")).to be_instance_of(Card)
|
31
|
-
expect(Card.cache.read("*head")).not_to be_nil
|
32
|
-
end
|
33
|
-
|
34
|
-
it "returns virtual cards and caches them as missing" do
|
35
|
-
Card::Auth.as_bot do
|
36
|
-
card = Card.fetch("Joe User+*email")
|
37
|
-
expect(card).to be_a(Card).and have_name "Joe User+*email"
|
38
|
-
expect(card.format.render_raw).to eq("joe@user.com")
|
39
|
-
end
|
40
|
-
# card.content.should == 'joe@user.com'
|
41
|
-
# cached_card = Card.cache.read('joe_user+*email')
|
42
|
-
# cached_card.missing?.should be_true
|
43
|
-
# cached_card.virtual?.should be_true
|
44
|
-
end
|
45
|
-
|
46
|
-
it "fetches virtual cards after skipping them" do
|
47
|
-
expect(Card["A+*self"]).to be_nil
|
48
|
-
expect(Card.fetch("A+*self")).not_to be_nil
|
49
|
-
end
|
50
|
-
|
51
|
-
it "fetches newly virtual cards", as_bot: true do
|
52
|
-
expect(Card.fetch("A+virtual")).to be_nil
|
53
|
-
create "virtual+*right+*structure"
|
54
|
-
expect(Card.fetch("A+virtual")).not_to be_nil
|
55
|
-
end
|
56
|
-
|
57
|
-
it "fetches virtual set cards" do
|
58
|
-
aself = Card.fetch("A+*self")
|
59
|
-
Card::Cache.reset_all
|
60
|
-
Card.fetch "A+*self"
|
61
|
-
|
62
|
-
expect(aself.set_names).to include("Set+*type")
|
63
|
-
end
|
64
|
-
|
65
|
-
it "fetches structured cards" do
|
66
|
-
Card::Auth.as_bot do
|
67
|
-
Card.create! name: "y+*right+*structure", content: "Formatted Content"
|
68
|
-
Card.create! name: "a+y", content: "DB Content"
|
69
|
-
end
|
70
|
-
card = Card.fetch("a+y")
|
71
|
-
expect(card).to be_real.and have_content("Formatted Content").and have_db_content("DB Content")
|
72
|
-
end
|
73
|
-
|
74
|
-
it "handles name variants of cached cards" do
|
75
|
-
expect(Card.fetch("yomama+*self").name).to eq("yomama+*self")
|
76
|
-
expect(Card.fetch("YOMAMA+*self").name).to eq("YOMAMA+*self")
|
77
|
-
expect(Card.fetch("yomama", new: {}).name).to eq("yomama")
|
78
|
-
expect(Card.fetch("YOMAMA", new: {}).name).to eq("YOMAMA")
|
79
|
-
expect(Card.fetch("yomama!", new: { name: "Yomama" }).name)
|
80
|
-
.to eq("Yomama")
|
81
|
-
end
|
82
|
-
|
83
|
-
it "fetches junction of names" do
|
84
|
-
card = Card.fetch "A", "B"
|
85
|
-
expect(card).to be_instance_of(Card)
|
86
|
-
expect(card.name).to eq "A+B"
|
87
|
-
end
|
88
|
-
|
89
|
-
it "fetches junction of string, id, and codename" do
|
90
|
-
card = Card.fetch "Book", Card.fetch_id(:type), :structure
|
91
|
-
expect(card).to be_instance_of(Card)
|
92
|
-
expect(card.name).to eq "Book+*type+*structure"
|
93
|
-
end
|
94
|
-
|
95
|
-
it "fetches junction of name, card object, and codename" do
|
96
|
-
card = Card.fetch "Book".to_name, Card.fetch(:type), :structure
|
97
|
-
expect(card).to be_instance_of(Card)
|
98
|
-
expect(card.name).to eq "Book+*type+*structure"
|
99
|
-
end
|
100
|
-
|
101
|
-
it "does not recurse infinitely on template templates" do
|
102
|
-
expect(Card.fetch("*structure+*right+*structure")).to be_nil
|
103
|
-
end
|
104
|
-
|
105
|
-
it "expires card and dependencies on save" do
|
106
|
-
# Card.cache.dump # should be empty
|
107
|
-
Card.cache.soft.reset
|
108
|
-
expect(Card.cache.soft.store.keys).to eq([])
|
109
|
-
|
110
|
-
Card::Auth.as_bot do
|
111
|
-
a = Card.fetch("A")
|
112
|
-
expect(a).to be_instance_of(Card)
|
113
|
-
|
114
|
-
# expires the saved card
|
115
|
-
expect(a).to receive(:expire).and_call_original
|
116
|
-
# expect().to receive(:delete).with('a#SUBCARDS#').and_call_original
|
117
|
-
# expires plus cards
|
118
|
-
# expect(Card.cache).to receive(:delete).with('c+a')
|
119
|
-
# expect(Card.cache).to receive(:delete).with('d+a')
|
120
|
-
# expect(Card.cache).to receive(:delete).with('f+a')
|
121
|
-
# expect(Card.cache).to receive(:delete).with('a+b')
|
122
|
-
# expect(Card.cache).to receive(:delete).with('a+c')
|
123
|
-
# expect(Card.cache).to receive(:delete).with('a+d')
|
124
|
-
# expect(Card.cache).to receive(:delete).with('a+e')
|
125
|
-
# expect(Card.cache).to receive(:delete).with('a+b+c')
|
126
|
-
|
127
|
-
# expired including? cards
|
128
|
-
# expect(Card.cache).to receive(:delete).with('x').exactly(2).times
|
129
|
-
# expect(Card.cache).to receive(:delete).with('y').exactly(2).times
|
130
|
-
a.save!
|
131
|
-
end
|
132
|
-
end
|
133
|
-
|
134
|
-
describe "default option" do
|
135
|
-
context "when card doesn't exist" do
|
136
|
-
it "initializes new cards" do
|
137
|
-
card = Card.fetch "non-existent",
|
138
|
-
new: { default_content: "default content" }
|
139
|
-
expect(card.db_content).to eq "default content"
|
140
|
-
end
|
141
|
-
end
|
142
|
-
context "when new card exist" do
|
143
|
-
it "doesn't change anything" do
|
144
|
-
Card.new name: "new card",
|
145
|
-
"+sub" => { content: "some content" }
|
146
|
-
card = Card.fetch "new card+sub",
|
147
|
-
new: { default_content: "new content" }
|
148
|
-
expect(card.db_content).to eq "some content"
|
149
|
-
end
|
150
|
-
end
|
151
|
-
end
|
152
|
-
|
153
|
-
describe "preferences" do
|
154
|
-
before do
|
155
|
-
Card::Auth.signin Card::WagnBotID
|
156
|
-
end
|
157
|
-
|
158
|
-
it "prefers db cards to pattern virtual cards" do
|
159
|
-
Card.create! name: "y+*right+*structure",
|
160
|
-
content: "Formatted Content"
|
161
|
-
Card.create! name: "a+y", content: "DB Content"
|
162
|
-
card = Card.fetch("a+y")
|
163
|
-
expect(card).to be_not_virtual.and have_db_content "DB Content"
|
164
|
-
expect(card.rule(:structure)).to eq("Formatted Content")
|
165
|
-
end
|
166
|
-
|
167
|
-
it "prefers a pattern virtual card to trash cards" do
|
168
|
-
Card.create!(name: "y+*right+*structure", content: "Formatted Content")
|
169
|
-
Card.create!(name: "a+y", content: "DB Content")
|
170
|
-
Card.fetch("a+y").delete!
|
171
|
-
|
172
|
-
card = Card.fetch("a+y")
|
173
|
-
expect(card).to be_virtual.and have_content "Formatted Content"
|
174
|
-
end
|
175
|
-
|
176
|
-
it "recognizes pattern overrides" do
|
177
|
-
# ~~~ create right rule
|
178
|
-
Card.create!(name: "y+*right+*structure", content: "Right Content")
|
179
|
-
card = Card.fetch("a+y")
|
180
|
-
expect(card).to be_virtual.and have_content "Right Content"
|
181
|
-
|
182
|
-
# warn 'creating template'
|
183
|
-
tpr = Card.create! name: "RichText+y+*type plus right+*structure",
|
184
|
-
content: "Type Plus Right Content"
|
185
|
-
card = Card.fetch("a+y")
|
186
|
-
expect(card).to be_virtual.and have_content "Type Plus Right Content"
|
187
|
-
|
188
|
-
# ~~~ delete type plus right rule
|
189
|
-
tpr.delete!
|
190
|
-
card = Card.fetch("a+y")
|
191
|
-
expect(card).to be_virtual.and have_content "Right Content"
|
192
|
-
end
|
193
|
-
|
194
|
-
it "does not hit the database for every fetch_virtual lookup" do
|
195
|
-
card_double = class_double("Card")
|
196
|
-
Card.create!(name: "y+*right+*structure", content: "Formatted Content")
|
197
|
-
Card.fetch("a+y")
|
198
|
-
expect(card_double).not_to receive(:find_by_key)
|
199
|
-
Card.fetch("a+y")
|
200
|
-
end
|
201
|
-
|
202
|
-
it "does not be a new_record after being saved" do
|
203
|
-
Card.create!(name: "growing up")
|
204
|
-
card = Card.fetch("growing up")
|
205
|
-
expect(card.new_record?).to be_falsey
|
206
|
-
end
|
207
|
-
end
|
208
|
-
|
209
|
-
describe "default_content option" do
|
210
|
-
context "when card doesn't exist" do
|
211
|
-
it "initializes card with default content" do
|
212
|
-
card = Card.fetch "non-existent",
|
213
|
-
new: { default_content: "default content" }
|
214
|
-
expect(card).to have_db_content "default content"
|
215
|
-
end
|
216
|
-
end
|
217
|
-
context "when new card exist" do
|
218
|
-
it "doesn't change content" do
|
219
|
-
Card.new name: "new card", "+sub" => { content: "some content" }
|
220
|
-
card = Card.fetch "new card+sub", new: { default_content: "new content" }
|
221
|
-
expect(card).to have_db_content "some content"
|
222
|
-
end
|
223
|
-
end
|
224
|
-
end
|
225
|
-
end
|
226
|
-
|
227
|
-
describe "#fetch new: { ... }" do
|
228
|
-
it "returns a new card if it doesn't find one" do
|
229
|
-
new_card = Card.fetch "Never Seen Me Before", new: {}
|
230
|
-
expect(new_card).to be_a(Card).and be_a_new_record
|
231
|
-
expect { new_card.save! }.to increase_card_count.by(1)
|
232
|
-
end
|
233
|
-
|
234
|
-
it "returns a card if it finds one" do
|
235
|
-
new_card = Card.fetch "A+B", new: {}
|
236
|
-
expect(new_card).to be_a(Card).and be_real
|
237
|
-
expect { new_card.save! }.not_to increase_card_count
|
238
|
-
end
|
239
|
-
|
240
|
-
it "takes a second hash of options as new card options" do
|
241
|
-
new_card = Card.fetch "Never Before", new: { type: "Image" }
|
242
|
-
expect(new_card).to be_a(Card).and be_a_new_record
|
243
|
-
.and have_type(:image)
|
244
|
-
expect(Card.fetch("Never Before", new: {})).to have_type(:basic)
|
245
|
-
end
|
246
|
-
end
|
247
|
-
|
248
|
-
describe "#fetch_virtual" do
|
249
|
-
before do
|
250
|
-
Card::Auth.as_bot do
|
251
|
-
Card.create! name: "testsearch+*right+*structure",
|
252
|
-
content: '{"plus":"_self"}', type: "Search"
|
253
|
-
end
|
254
|
-
end
|
255
|
-
it "finds cards with *right+*structure specified" do
|
256
|
-
expect(Card.fetch("A+testsearch".to_name))
|
257
|
-
.to be_virtual.and have_type(:search_type)
|
258
|
-
.and have_content '{"plus":"_self"}'
|
259
|
-
end
|
260
|
-
context "fetched virtual card with new args" do
|
261
|
-
it "fetchs the virtual card with type set in patterns" do
|
262
|
-
Card.fetch "+testsearch", new: { name: "+testsearch",
|
263
|
-
supercard: Card["home"] }
|
264
|
-
|
265
|
-
c = Card.fetch("Home+testsearch".to_name)
|
266
|
-
expect(c).to be_virtual.and have_type(:search_type)
|
267
|
-
.and have_content('{"plus":"_self"}')
|
268
|
-
|
269
|
-
patterns = c.instance_variable_get("@patterns").map(&:to_s)
|
270
|
-
expect(patterns).to include("Search+*type")
|
271
|
-
end
|
272
|
-
end
|
273
|
-
end
|
274
|
-
|
275
|
-
describe "#id" do
|
276
|
-
it "handles integer args" do
|
277
|
-
expect(Card.id(1234)).to eq(1234)
|
278
|
-
end
|
279
|
-
|
280
|
-
it "handles card args" do
|
281
|
-
a = Card["A"]
|
282
|
-
expect(Card.id(a)).to eq(a.id)
|
283
|
-
end
|
284
|
-
|
285
|
-
it "handles symbols" do
|
286
|
-
expect(Card.id(:structure)).to eq(Card::StructureID)
|
287
|
-
end
|
288
|
-
end
|
289
|
-
|
290
|
-
describe "#exists?" do
|
291
|
-
it "is true for cards that are there" do
|
292
|
-
expect(Card.exists?("A")).to eq(true)
|
293
|
-
end
|
294
|
-
|
295
|
-
it "is false for cards that aren't" do
|
296
|
-
expect(Card.exists?("Mumblefunk is gone")).to eq(false)
|
297
|
-
end
|
298
|
-
end
|
299
|
-
|
300
|
-
describe "#fetch_name" do
|
301
|
-
example "symbol" do
|
302
|
-
expect(Card.fetch_name(:all)).to eq "*all"
|
303
|
-
end
|
304
|
-
|
305
|
-
example "string" do
|
306
|
-
expect(Card.fetch_name("home")).to eq "Home"
|
307
|
-
end
|
308
|
-
|
309
|
-
example "id" do
|
310
|
-
expect(Card.fetch_name(Card::BasicID)).to eq "RichText"
|
311
|
-
end
|
312
|
-
|
313
|
-
example "invalid id" do
|
314
|
-
expect(Card.fetch_name("~1836/[[/assets/fonts")).to be_nil
|
315
|
-
end
|
316
|
-
|
317
|
-
example "array" do
|
318
|
-
expect(Card.fetch_name(%w[a b])).to eq "A+B"
|
319
|
-
end
|
320
|
-
|
321
|
-
example "param list" do
|
322
|
-
expect(Card.fetch_name("fruit", :type, "*create")).to eq "Fruit+*type+*create"
|
323
|
-
end
|
324
|
-
|
325
|
-
example "name doesn't exist" do
|
326
|
-
expect(Card.fetch_name("unknown_name")).to eq nil
|
327
|
-
end
|
328
|
-
|
329
|
-
example "fallback policy" do
|
330
|
-
name = Card.fetch_name("unknown_name") { "Unknown Name" }
|
331
|
-
expect(name).to eq "Unknown Name"
|
332
|
-
end
|
333
|
-
|
334
|
-
it "doesn't fetch virtual names" do
|
335
|
-
expect(Card.fetch_name(:all, :self, :create)).to eq nil
|
336
|
-
end
|
337
|
-
end
|
338
|
-
end
|