• Timothy Andrew's avatar
    Fix failing tests relating to backporting ee!581. · dd3b738d
    Timothy Andrew authored
    1. `GitPushService` was still using `{merge,push}_access_level_attributes` instead
       of `{merge,push}_access_levels_attributes`.
    
    2. The branches API creates access levels regardless of the state of the
       `developers_can_{push,merge}` parameters. This is in line with the UI,
       where Master access is the default for a new protected branch.
    
    3. Use `after(:build)` to create access levels in the
       `protected_branches` factory, so that `factories_spec` passes. It
       only builds records, so we need to create access levels on `build` as
       well.
    dd3b738d
project_spec.rb 46.3 KB